[Issue 2367] New: Overloading error

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat Sep 20 11:01:55 PDT 2008


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

           Summary: Overloading error
           Product: D
           Version: unspecified
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla at digitalmars.com
        ReportedBy: andrei at metalanguage.com


The following code does not compile:

struct S {
    void foo(in char[] s) {}
    void foo(in dchar[] s) {}
}

void main(string[] args) {
    S s;
    s.foo("a");
}

The second overload should not even be considered.


-- 



More information about the Digitalmars-d-bugs mailing list