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

           Summary: invalid type accepted if evaluated while errors are
                    gagged
           Product: D
           Version: unspecified
          Platform: Other
        OS/Version: Windows
            Status: NEW
          Keywords: accepts-invalid
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nob...@puremagic.com
        ReportedBy: r.sagita...@gmx.de


--- Comment #0 from Rainer Schuetze <r.sagita...@gmx.de> 2010-06-04 05:58:53 
PDT ---
The D2 code (tried with DMD 2.042 and 2.046):

static if(__traits(compiles,A.sizeof)) pragma(msg, "A.sizeof compiles!");

class A
{
    void foo(B b);
}


compiles without error with "dmd -c test.d" or even links if foo is made final.

This is caused by the error when evaluating B is muted while processing
__traits(compiles), but A is never revisited later.

A debug version of DMD outputs

ty = 37, '_error_'
assert glue.c(1059) 0

This can happen whenever globals.gag is non-zero, i.e. with speculative
semantic analysis.

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

Reply via email to