digitalmars.D.bugs - [Issue 8492] New: can't infer type in static assert
- d-bugmail puremagic.com (45/45) Aug 01 2012 http://d.puremagic.com/issues/show_bug.cgi?id=8492
- d-bugmail puremagic.com (7/7) Aug 01 2012 http://d.puremagic.com/issues/show_bug.cgi?id=8492
http://d.puremagic.com/issues/show_bug.cgi?id=8492 Summary: can't infer type in static assert Product: D Version: D2 Platform: All OS/Version: All Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: nobody puremagic.com ReportedBy: ellery-newcomer utulsa.edu --- Comment #0 from Ellery Newcomer <ellery-newcomer utulsa.edu> 2012-08-01 19:27:38 PDT --- with the attached file, dmd multi_index.d compiles, but dmd multi_index.d -version=A fails, giving multi_index.d(13): Error: static assert (is(typeof(delegate pure nothrow safe void() { assert(this,"null this"); RARange r = void; _error_ = __error; } ))) is false multi_index.d(41): instantiated from here: MultiIndexContainer!(A,IndexedBy!(__T12RandomAccessZ)) The difference is the following: version(A) { static assert(is(typeof( { RARange r = void; auto h = r.front; }))); }else { void flurby() { RARange r = void; auto h = r.front; } } both should compile. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Aug 01 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8492 --- Comment #1 from Ellery Newcomer <ellery-newcomer utulsa.edu> 2012-08-01 19:28:55 PDT --- Created an attachment (id=1132) test case -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Aug 01 2012