April 06, 2012 [Issue 7846] New: Forward referenced storage class is not applied in certain cases | ||||
---|---|---|---|---|
| ||||
http://d.puremagic.com/issues/show_bug.cgi?id=7846 Summary: Forward referenced storage class is not applied in certain cases Product: D Version: D2 Platform: All OS/Version: All Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: nobody@puremagic.com ReportedBy: timon.gehr@gmx.ch --- Comment #0 from timon.gehr@gmx.ch 2012-04-06 02:26:03 PDT --- static assert(is(typeof(x)==const(int))); // pass static assert(!is(typeof({x=2;}))); // pass pragma(msg, typeof(x)); // "int" pragma(msg, is(typeof({x=2;}))); // "true" const int x; pragma(msg, typeof(x)); // "const(int)" pragma(msg, is(typeof({x=2;}))); // "false" -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
April 21, 2012 [Issue 7846] Forward referenced storage class is not applied in certain cases | ||||
---|---|---|---|---|
| ||||
Posted in reply to timon.gehr@gmx.ch | http://d.puremagic.com/issues/show_bug.cgi?id=7846 SomeDude <lovelydear@mailmetrash.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |lovelydear@mailmetrash.com --- Comment #1 from SomeDude <lovelydear@mailmetrash.com> 2012-04-21 11:03:06 PDT --- I don't understand. I have to add const int x; at the beginning in order for this test to pass. Then I get: PS E:\DigitalMars\dmd2\samples> dmd -c bug.d const(int) false bug.d(11): Error: declaration bug.main.x is already defined const(int) false -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
Copyright © 1999-2021 by the D Language Foundation