template<typename T, typename U = int>
struct A {};
template<typename T, typename U>
struct A<T*, U> {};
template<typename T, typename U>
struct A<T[], U> {};
int main()
{
A<int*> m; // m: A<int*, int>
A<int[]> n; // n: A<int[], int>
return 0;
}
What's the difference between int[] and int* here as template arguments? Isn't int[] simply a pointer too?