October 24, 2008 Re: defered new feature | ||||
|---|---|---|---|---|
| ||||
Posted in reply to downs | Reply to Downs, > BCS wrote: > >> to bad it doesn't compile :( Oops. http://codepad.org/CYTJzhJc > gentoo-pc ~ $ cat test113.d && echo "----" && gdc test113.d -o test113 > && ./test113 module test113; > > typedef bool Bogus; > const Bogus bogus = false; > class A { this() { this = new B; } this(Bogus) { } } class B : A { > this() { super(bogus); /* rest of constructor */ } } > > import std.stdio; > void main() { writefln(new A); } > ---- > test113.B > gentoo-pc ~ $ | |||
Copyright © 1999-2021 by the D Language Foundation
Permalink
Reply