[Issue 3809] Struct initializers apparently always CTFE'd, and incorrectly
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Fri Apr 23 12:51:57 PDT 2010
http://d.puremagic.com/issues/show_bug.cgi?id=3809
--- Comment #2 from Don <clugdbug at yahoo.com.au> 2010-04-23 12:51:54 PDT ---
Starting with the simple thing: the missing line number in the division by 0
error message.
PATCH: interpret.c, near the start of BinExp::interpretAssignCommon().
else if (e1->op != TOKslice)
{ /* Look for special case of struct being initialized with 0.
*/
if (type->toBasetype()->ty == Tstruct && newval->op == TOKint64)
{
- newval = type->defaultInitLiteral();
+ newval = type->defaultInitLiteral(loc);
}
newval = Cast(type, type, newval);
e = newval;
}
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list