Skip to content

Commit

Permalink
Merge pull request #4775 from WalterBright/fix14430
Browse files Browse the repository at this point in the history
fix Issue 14430 - [REG2.060] Null parameter is detected as non-null
  • Loading branch information
yebblies committed Jun 26, 2015
2 parents ad63ba2 + b53c44e commit 1ea328e
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/backend/cod1.c
Original file line number Diff line number Diff line change
Expand Up @@ -4249,8 +4249,8 @@ code *loaddata(elem *e,regm_t *pretregs)
}
else if (I64 && sz == 16)
{
ce = movregconst(CNIL,findreglsw(forregs),e->EV.Vcent.lsw,0);
ce = movregconst(ce,findregmsw(forregs),e->EV.Vcent.msw,0);
ce = movregconst(CNIL,findreglsw(forregs),e->EV.Vcent.lsw,64);
ce = movregconst(ce,findregmsw(forregs),e->EV.Vcent.msw,64);
}
else
assert(0);
Expand Down
12 changes: 12 additions & 0 deletions test/runnable/test42.d
Original file line number Diff line number Diff line change
Expand Up @@ -5983,6 +5983,17 @@ label:
assert(s.num == 10);
}

/***************************************************/
// 14430

void setCookie(long x = 1L << 32L, string y = null){
assert(y.ptr is null);
}

void test14430(){
setCookie();
}

/***************************************************/

int main()
Expand Down Expand Up @@ -6277,6 +6288,7 @@ int main()
test10642();
test7436();
test12138();
test14430();

writefln("Success");
return 0;
Expand Down

0 comments on commit 1ea328e

Please sign in to comment.