overloading functions against function templates

ponce aliloko at gmail.com
Thu Jul 30 17:46:57 PDT 2009


How would compete template specialization and matching functions ?

like :

double foo(double x) { return x * 2; }
double foo(T)(T x) { return x * 3; }
double foo(T : double)(T x) { return x * 4; }

writeln(foo(4.0));




More information about the Digitalmars-d mailing list