[Issue 11064] New: D should support block statements inside functions
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Wed Sep 18 07:45:09 PDT 2013
http://d.puremagic.com/issues/show_bug.cgi?id=11064
Summary: D should support block statements inside functions
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Severity: enhancement
Priority: P2
Component: DMD
AssignedTo: nobody at puremagic.com
ReportedBy: rswhite4 at googlemail.com
--- Comment #0 from rswhite4 at googlemail.com 2013-09-18 07:45:08 PDT ---
Code:
----
const { /// [1]
int a = 3;
}
void main()
{
const { /// [2]
int b = 4;
}
}
----
[1] is currently supported, but [2] not.
I see no reason for this limitation.
debug statements behave the same way:
debug {
/// debug code
}
So the same should also apply to const and immutable and maybe also for pure,
nothrow etc.
--
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