← Back to index
|
Original Bugzilla link
Bug 6859 – Segfault when abstract method uses with contract.
Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
Other
OS
Windows
Creation time
2011-10-27T09:32:00Z
Last change time
2011-11-08T00:34:51Z
Keywords
patch, wrong-code
Assigned to
nobody
Creator
Koichi.Takio
Comments
Comment #0
by Koichi.Takio — 2011-10-27T09:32:59Z
This code doesn't work! -------------------- import std.stdio; void main(string[] args) { auto t = new Child; t.fuga(); writeln("done."); } class Parent { public: bool isHage() const @property; public: abstract void fuga() out { assert(isHage); } body { } } class Child : Parent { override bool isHage() const @property { return true; } override void fuga() { //nop } } --------------------
Comment #1
by k.hara.pg — 2011-10-28T03:35:48Z
https://github.com/D-Programming-Language/dmd/pull/478
Comment #2
by bugzilla — 2011-11-08T00:34:51Z
https://github.com/D-Programming-Language/dmd/commit/17d9baeb9f9c000b1b6828baa0bb7c73cb38e31b
https://github.com/D-Programming-Language/dmd/commit/8aa616d1a6d25ca7b358d08b1aab1d948597a835