import std.stdio;
template Test(A ...) {
template Test(B) {
void Test(A a, B b) { writefln(a, b); }
}
}
void main() {
alias Test!(char[], int) Temp;
alias Temp!(float) T;
}
--------------
Compiling the above code produces: "Error: error: forward reference of B".
B is quite obviously not forward-referenced in the code.
Comment #1 by r.sagitario — 2009-09-18T01:38:40Z
I could not reproduce this bug with DMD 1.047 and DMD 2.032.
Comment #2 by clugdbug — 2009-09-18T15:07:14Z
Fixed long ago. Failed in 0.175, worked on DMD1.006. Still works.