However, if the template-id is dependent, subsequent template
argument substitution still applies to the template-id.
[Example 2: template<typename...>using void_t =void;
template<typename T> void_t<typename T::foo> f();
f<int>(); // error: int does not have a nested type foo — end example]
The defining-type-id in an alias template declaration shall not refer to
the alias template being declared.
The type produced by an alias template
specialization shall not directly or indirectly make use of that specialization.
[Example 3: template<class T>struct A;
template<class T>using B =typename A<T>::U;
template<class T>struct A {typedef B<T> U;
};
B<short> b; // error: instantiation of B<short> uses own type via A<short>::U — end example]
The type of a lambda-expression
appearing in an alias template declaration
is different between instantiations of that template,
even when the lambda-expression is not dependent.
[Example 4: template<class T>using A =decltype([]{}); // A<int> and A<char> refer to different closure types — end example]