www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 7607] New: ICE(e2ir.c) with -inline, opApply, a template, multiple functions

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=7607

           Summary: ICE(e2ir.c) with -inline, opApply, a template,
                    multiple functions
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: ice
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody puremagic.com
        ReportedBy: mailme+d nilsb.dyndns.org



struct Iter {
    int opApply(int delegate(ref int)) {
        return 0;
    }
}
version(inlinec) { // see below
} else {
    void f() body {
        g(Iter()); // without this call: no error
    }
}
void g(S = void)(Iter i) { // without the template: no error
    foreach(_; i) { // without the loop: no error
        f(); // without this call: no error
    }
}
/*
$ dmd -c -inline test.d
g(S = void)
Internal error: e2ir.c 688
*/

//This may be a different issue or just a consequence of the former ICE:
version(inlinec) {
    void f() out {} body {
        g(Iter());
    }
    void main() {
        f();
    }
}
/*
$ dmd -c -inline test.d -version=inlinec
Statement::doInline()
__returnLabel:
{
}

dmd: inline.c:469: virtual Expression* Statement::doInline(InlineDoState*):
Assertion `0' failed.
*/

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Feb 28 2012
parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=7607


Nils <nilsbossung googlemail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |WORKSFORME



---
issue disappeared in 2.061

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jan 06 2013