It's intresting. So the only way to pass "a" to overloaded function like that ?
void foo(T)(ref T) { writeln("true"); }
void foo(T)(auto ref in T) { writeln("false"); }
enum int a = 10;
foo(a); // false
int b = 1;
foo(b); // true
It's intresting. So the only way to pass "a" to overloaded function like that ?
void foo(T)(ref T) { writeln("true"); }
void foo(T)(auto ref in T) { writeln("false"); }
enum int a = 10;
foo(a); // false
int b = 1;
foo(b); // true