The following source:
base.d
----
template Template(T:Base)
{
}
class Base
{
}
----
derived.d
----
import base;
mixin Template!(Derived);
class Derived : Base {}
----
Produces the errors:
----
derived.d(3): Error: class derived.Derived base class is forward referenced by Base
derived.d(2): Error: mixin Template!(Derived) does not match template declaration Template(T : Base
----
When compiled with dmd1 and 2, using `dmd base.d derived.d`. Moving the mixin after the definition of Derived seems to fix the error.
Comment #1 by robert — 2010-12-09T09:27:45Z
*** This issue has been marked as a duplicate of issue 4033 ***