Broken in 2.037, works in 2.036:
void foo(T)(T arg) {}
void foo(T)(T arg, uint bar) {}
void main() {
foo(1); // works
foo(1, 2); // works
foo!(uint)(1); // Error: template instance foo!(uint) matches
// more than one template declaration, foo(T) and foo(T)
}
Comment #1 by bugzilla — 2009-12-06T03:08:42Z
I know there was this change, but before it was a bit erratic what it did. I'll argue that the compiler is correctly saying it's an error.
Code can decide to do template function type inference, or overloading, but not both at the same time. By not specifying enough in the specialization, then inference rules are applied.
Trying to do both inference and overloading results in a complicated morass. Better to leave it an error.