I have an aliased template, defined with the using directive:
template<typename A>
using T=TC<decltype(A::b),decltype(A::c)>;
Does C++11 offer a mechanism to forward declare this template alias T
?
I tried:
template<typename> struct T;
and:
template<typename>
using T;
but both return compiler errors ("conflict with previous declaration"). I am using gcc 4.8.
What is the syntax to get this to work?
No, it's not possible.
What you want to do is forward declare TC
, then define T
immediately below it.
template<typename T, typename U>
struct TC;
template<typename A>
using T=TC<decltype(A::b),decltype(A::c)>;
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With