#include <iostream>
#include<vector>
//-------------------vvvvvvvvvvv---->nontype parameter
template<typename U, std::size_t T>
struct A {
struct B {
struct C {
std::vector<U> count; //count is a std::vector
C(): count(T) {
std::cout<<"size of count vector is: "<<count.size()<<std::endl;
}
//C c;//this won't work here as C is INCOMPLETE at this point
};
C c; //THIS WORKS HERE because C is COMPLETE at this point
// B b;//this wont work here as B is INCOMPLETE at this point
};
B b; //THIS WORKS HERE because B is INCOMPLETE at this point
};//added this
int main()
{
A<int, 5>::B::C c;
return 0;
}