Skip to content

Commit

Permalink
Merge pull request #4466 from yebblies/foreachcast
Browse files Browse the repository at this point in the history
[DDMD] Add casts to allow conversion to foreach
  • Loading branch information
9rnsr committed Mar 11, 2015
2 parents ee24a3e + d9fab2d commit f5cb574
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/ctfeexpr.c
Expand Up @@ -1358,7 +1358,7 @@ int ctfeCmpArrays(Loc loc, Expression *e1, Expression *e2, uinteger_t len)
// If they aren't strings, we just need an equality check rather than
// a full cmp.
bool needCmp = ae1->type->nextOf()->isintegral();
for (size_t i = 0; i < len; i++)
for (size_t i = 0; i < (size_t)len; i++)
{
Expression *ee1 = (*ae1->elements)[(size_t)(lo1 + i)];
Expression *ee2 = (*ae2->elements)[(size_t)(lo2 + i)];
Expand Down
2 changes: 1 addition & 1 deletion src/traits.c
Expand Up @@ -385,7 +385,7 @@ Expression *pointerBitmap(TraitsExp *e)
d_uns64 arrayoff = offset;
d_uns64 nextsize = t->next->size();
d_uns64 dim = t->dim->toInteger();
for (size_t i = 0; i < dim; i++)
for (d_uns64 i = 0; i < dim; i++)
{
offset = arrayoff + i * nextsize;
t->next->accept(this);
Expand Down

0 comments on commit f5cb574

Please sign in to comment.