hello!
I'm struggling with compile error C3200
http://msdn.microsoft.com/en-us/library/3xwxftta.aspx discusses the problem and gives as an example:
// C3200.cpp
template<typename T>
class X
{
};
template<template<typename U> class T1, typename T2>
class Y
{
};
int main()
{
Y<int, int> y; // C3200
}
and suggests that instead
Y<X, int> y;
must be used. but i don't really understand this... why can't it be
Y<X<int>, int> y;
? that would make more sense for me because in the suggested way the actual type of y is still not really defined.. if i extend the given example with some variables i get this:
// C3200.cpp
template<typename T>
class X
{
char someChar;
T someOtherVar;
};
template<template<typename U> class T1, typename T2>
class Y
{
T1 var1;
T2 var2;
};
so if i just specify Y y; as in the suggested solution, the compiler still does not know how many bytes to reserve for y - no?
can someone explain me what's going on?
thanks!