[Issue 569] New: Bogus forward reference error in template inside variadic template

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat Nov 18 18:42:10 PST 2006


http://d.puremagic.com/issues/show_bug.cgi?id=569

           Summary: Bogus forward reference error in template inside
                    variadic template
           Product: D
           Version: 0.174
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla at digitalmars.com
        ReportedBy: daekharel at gmail.com


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.


-- 




More information about the Digitalmars-d-bugs mailing list