hello.
here I have some code sample.
I'm not sure if this is my incorrect code or incorrect dmd behavior.
Intention is C2 to inherit C1's void writetext(alias A1)()
and instantiate it with this.writetext!(typeof(this))();
import std.stdio;
class C1
{
void writetext()
{
this.writetext!(typeof(this))();
}
void writetext(alias A1)()
{
writeln("C1 writetext(alias A1) ", this);
}
}
class C2 : C1
{
override void writetext()
{
// if line 21 is commented and line 22 is uncommented - this compiles ok
this.writetext!(typeof(this))();
// super.writetext!(typeof(this))();
}
}
void main()
{
auto c2 = new C2;
c2.writetext();
}