← Back to index
|
Original Bugzilla link
Bug 6320 – non-pure constructor can be called using new
Status
RESOLVED
Resolution
DUPLICATE
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2011-07-14T21:18:00Z
Last change time
2013-07-13T23:52:46Z
Assigned to
nobody
Creator
yebblies
Comments
Comment #0
by yebblies — 2011-07-14T21:18:34Z
The following compiles without error in dmd 2.054 class A { this () { static int notpure; notpure++; } } pure void main() { auto x = new A(); }
Comment #1
by yebblies — 2013-07-13T23:02:16Z
This has since been fixed.
Comment #2
by k.hara.pg — 2013-07-13T23:52:46Z
Fixed in 2.064a. *** This issue has been marked as a duplicate of issue 10254 ***