Summary: Unfair function address overload resolution
           Product: D
           Version: unspecified
          Platform: Other
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD

--- Comment #0 from 2012-01-01 17:25:50 PST ---
Tested with DMD 2.057

auto foo(int x){return x;}
auto foo(double x){return x;}

void main() {
    auto x = (&foo)(1);   // ok
    auto y = (&foo)(1.0); // fail

Error: cannot implicitly convert expression (1) of type double to int

The code should either compile, or both lines should fail.

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to