[Issue 6859] New: Segfault when abstract method uses with contract.
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Thu Oct 27 09:34:08 PDT 2011
http://d.puremagic.com/issues/show_bug.cgi?id=6859
Summary: Segfault when abstract method uses with contract.
Product: D
Version: D2
Platform: Other
OS/Version: Windows
Status: NEW
Severity: normal
Priority: P2
Component: DMD
AssignedTo: nobody at puremagic.com
ReportedBy: Koichi.Takio at gmail.com
--- Comment #0 from Koichi <Koichi.Takio at gmail.com> 2011-10-27 09:32:59 PDT ---
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
}
}
--------------------
--
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