[Issue 14534] Front-end should lower all non-scalar condition expressions
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Thu May 7 14:51:28 PDT 2015
https://issues.dlang.org/show_bug.cgi?id=14534
--- Comment #6 from Iain Buclaw <ibuclaw at gdcproject.org> ---
This in particular what really irks me.
---
int test()
{
int[int] aa = [1:2];
int[] array = [1,2];
aa.remove(1);
array.length = 0;
if (__ctfe)
assert(!aa);
else
assert(aa);
if (__ctfe)
assert(!array);
else
assert(array);
return 1;
}
---
We have a split brain between what CTFE evaluates as true vs. runtime!
--
More information about the Digitalmars-d-bugs
mailing list