check instance of nested variadic template

Gianni Pisetta via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Fri Nov 4 08:50:36 PDT 2016


Hi all,
I am having issues finding a solution for this, i want to check 
if an alias is an istance of a variadic template nested in 
another variadic template.
Here is an example:

template A(As...) {
     template B(Bs...) {
     }
}

alias BI = A!(1,2).B!(3,4,5);

Now i want to test if BI is an istance of A.B, but i can't do 
something like this:

static if ( is( BI == A!As.B!Bs, As..., Bs... ) ) {
     // Do Something
}

there is some sort of workaround?

Thanks,
Gianni


More information about the Digitalmars-d-learn mailing list