digitalmars.D.bugs - [Issue 7386] New: Can't use a 'version' that was set inside 'static if'
- d-bugmail puremagic.com (27/27) Jan 28 2012 http://d.puremagic.com/issues/show_bug.cgi?id=7386
http://d.puremagic.com/issues/show_bug.cgi?id=7386 Summary: Can't use a 'version' that was set inside 'static if' Product: D Version: D2 Platform: All OS/Version: All Status: NEW Keywords: rejects-valid Severity: major Priority: P2 Component: DMD AssignedTo: nobody puremagic.com ReportedBy: cbkbbejeap mailinator.com --- Comment #0 from Nick Sabalausky <cbkbbejeap mailinator.com> 2012-01-28 03:56:26 PST --- static if(true) version = Foo; version(Foo) {} test.d(2): Error: version Foo defined after use The compiler's evaluation seems to occur in the wrong order ("versions before static ifs" instead of "top to bottom"), because this works: static if(true) version = Foo; static if(true) version(Foo) {} -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Jan 28 2012