[Issue 13382] [e2ir] compare string to int - leads to ICE in e2ir.c 1902

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Thu Sep 11 15:37:26 PDT 2014


https://issues.dlang.org/show_bug.cgi?id=13382

--- Comment #2 from hsteoh at quickfur.ath.cx ---
For small code examples, you can just post the entire code in a comment, like
so:
-----
import std.stdio;
void main () {
    string sn;
    if ((sn = readln ) > 0) {
    }
}
-----

There is no line number in the error message probably because by the time the
compiler getse to e2ir.c, it's already emitting code, and by that point the
semantic passes may have transformed the code significantly so that line number
information may not be readily available.

In any case, the error is caused by the `if ((sn = readln) > 0)` line. Now, to
hack the dmd makefiles so that I can get it to build with debugging symbols...

--


More information about the Digitalmars-d-bugs mailing list