[Issue 4011] New: Incorrect function overloading using mixins

d-bugmail at puremagic.com d-bugmail at puremagic.com
Fri Mar 26 11:59:09 PDT 2010


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

           Summary: Incorrect function overloading using mixins
           Product: D
           Version: unspecified
          Platform: Other
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody at puremagic.com
        ReportedBy: bugzilla at digitalmars.com


--- Comment #0 from Walter Bright <bugzilla at digitalmars.com> 2010-03-26 11:59:08 PDT ---
------- a.d -------------------
enum FooA { fooA };
void bar(FooA x) {}
------- test.d ----------------
import a;
alias a.bar bar;
mixin(`
enum FooB { fooB };
void bar(FooB x) {}
`);

void test()
{
    bar(FooA.fooA);
    bar(FooB.fooB); //error
}
------------------------------

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


More information about the Digitalmars-d-bugs mailing list