https://d.puremagic.com/issues/show_bug.cgi?id=12286

           Summary: Can't use two alias parameters to class and subclass
                    field
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: DMD
        AssignedTo: [email protected]
        ReportedBy: [email protected]


--- Comment #0 from Vladimir Panteleev <[email protected]> 2014-03-02 
21:10:49 EET ---
//////////// test.d ///////////
class A     { int i; }
class B : A { int j; }

template copy(alias a, alias b)
{
    void copy() { a = b; }
}

class C : B
{
    alias copyIJ = copy!(i, j);
}
///////////////////////////////

Error:
test.d(11): Error: template instance copy!(i, j) copy!(i, j) is nested in both
A and B

The template should be nested in the descendant type.

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

Reply via email to