https://issues.dlang.org/show_bug.cgi?id=15225

          Issue ID: 15225
           Summary: cannot overload directly aliased function literals
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Keywords: rejects-valid
          Severity: major
          Priority: P1
         Component: dmd
          Assignee: [email protected]
          Reporter: [email protected]

Test case:
---
alias foo = (int x) => x;
alias foo = (string x) => x;

void main()
{
    foo(1);
    foo("a");    // line 7
}

Output:
---
test.d(7): Error: function literal __lambda4 (int x) is not callable using
argument types (string)

--

Reply via email to