[Issue 8696] New: Compiler reports incorrect dangling else with version attributes
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Wed Sep 19 12:15:28 PDT 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8696
Summary: Compiler reports incorrect dangling else with version
attributes
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Severity: normal
Priority: P2
Component: DMD
AssignedTo: nobody at puremagic.com
ReportedBy: alex at lycus.org
--- Comment #0 from Alex Rønne Petersen <alex at lycus.org> 2012-09-19 21:16:22 CEST ---
$ cat test.d
version (Posix):
version (linux)
{
}
else version (OSX)
{
}
else
{
}
$ <> dmd -w -lib test.d
test.d(9): Warning: else is dangling, add { } after condition at test.d(1)
test.d(6): Warning: else is dangling, add { } after condition at test.d(1)
I don't see any reason at all that this should be considered a dangling else
case.
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list