[Issue 2064] Segfault with mixin(for/foreach) with empty loop body

d-bugmail at puremagic.com d-bugmail at puremagic.com
Fri Apr 3 04:30:52 PDT 2009


http://d.puremagic.com/issues/show_bug.cgi?id=2064


clugdbug at yahoo.com.au changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |patch




------- Comment #2 from clugdbug at yahoo.com.au  2009-04-03 06:30 -------
statement.c,  in Statement *ForStatement::semantic(Scope *sc)

around line 1129. body = body->semantic(sc);
but body is null in this case.

Trivial fix:

    if (body) body = body->semantic(sc);


-- 



More information about the Digitalmars-d-bugs mailing list