There is a way to capture the return type/parameters of a templated function like:

void add(T)(T t){}

Yes, i know that the template don´t have any type until explicitly coded like:

Or another solution like getting the string function declaration will be enough:
"void add(T)(T t)"

Like what happens with:

void other_add(int x){}
writeln( typeof(__traits(getMember, Module, "other_add")).stringof ); //output: void(int x)

Reply via email to