On Tue, 27 Nov 2018 02:00:44 +0000, PacMan wrote:
> f is defined as:
>
>> void f(T)(T t, string p)
>> if(is(T == A) || is(T == B))
>>{
>> // ...
>>}
>
> my goal is get "p" as string.
`f` is a template that generates functions. Before you instantiate that
template, the function doesn't exist, so there's no function to get
parameters from.
You can get the parameter names of any instantiation of that template,
such as:
assert(ParameterIdentifierTuple!(f!A)[1] == "p");
