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

           Summary: Error when template is instantiated in a class
           Product: D
           Version: D2
          Platform: Other
        OS/Version: Mac OS X
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nob...@puremagic.com
        ReportedBy: rob...@octarineparrot.com


--- Comment #0 from Robert Clipsham <rob...@octarineparrot.com> 2011-05-12 
18:43:25 BST ---
The following code:
----
template Templ(alias T)
{
    alias T!int Templ;
}

class C(T) 
{
    Templ!C foo;
}

// Uncomment this to make the error go away
//Templ!C foo;

void main()
{
    C!int a;
}
----
Gives the error:
----
test.d(3): Error: template instance T is not a template declaration, it is a
class
----
When uncommenting the line mentioned in the code the error goes away,
presumably because the forward reference goes away.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to