[Issue 7066] New: You can redefine .init and .stringof without error
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Sun Dec 4 15:45:01 PST 2011
http://d.puremagic.com/issues/show_bug.cgi?id=7066
Summary: You can redefine .init and .stringof without error
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Severity: normal
Priority: P2
Component: DMD
AssignedTo: nobody at puremagic.com
ReportedBy: peter.alexander.au at gmail.com
--- Comment #0 from Peter Alexander <peter.alexander.au at gmail.com> 2011-12-04 15:44:59 PST ---
The .init and .stringof properties of types can be redefined. A lot of code
depends on the definition of .init, so being able to change this breaks a lot
of Phobos.
class Foo
{
static immutable int init;
static immutable int stringof;
}
int x = Foo.init;
int y = Foo.stringof;
DMD should give an error just like it does for .sizeof, .alignof, and .mangleof
--
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