April 08, 2006
http://d.puremagic.com/bugzilla/show_bug.cgi?id=96

           Summary: Unable to overload functions injected from mixins.
           Product: D
           Version: 0.151
          Platform: PC
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla@digitalmars.com
        ReportedBy: daiphoenix@lycos.com


The following code doesn't compile:

template T1() {
        void func(int x) { }
}

template T2() {
        void func() { }
}

mixin T1!();
mixin T2!();

void main()
{
        func(); // A name conflict occurs here between the two func's.
}


-- 

April 08, 2006
http://d.puremagic.com/bugzilla/show_bug.cgi?id=96





------- Comment #1 from daiphoenix@lycos.com  2006-04-08 16:23 -------
Note: If by design one does not want mixins to enable function overloading, then the doc should be clear on that. Specifically, on "If two different mixins are put in the same scope, and each define a declaration with the same name, there is an ambiguity error when the declaration is referenced:", http://www.digitalmars.com/d/mixin.html .


--