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

Timothee Cour <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
                 CC|                            |[email protected]
         Resolution|FIXED                       |---

--- Comment #6 from Timothee Cour <[email protected]> ---
re-opening, as the fix doesn't work with overloads:

```
--- main.d
void fun(int a, double b){}
version(with_overload)
void fun(double a, int b){}

void main(){
  fun(1.1, 2.1);
}
```

dmd main.d
Error: function test_all.fun(int a, double b) is not callable using argument
types (double, double)
cannot pass argument 1.1 of type double to parameter int a

dmd -version=with_overload main.d
Error: none of the overloads of fun are callable using argument types (double,
double), candidates are:
test_all.fun(int a, double b)
test_all.fun(double a, int b)

with -version=with_overload , it should show a similar error showing where
parameters mis-matcch

--

Reply via email to