views:

67

answers:

1

This is child's play, but I'm a bit of a vc n00b.

I get an error: error C2143: syntax error : missing ',' before '<'. on the second line of the following code:

template<int i, int j> 
class B : public A<i, j> { }

template<int i, int j> 
class A { }

Thanks for the help!

+5  A: 

You forgot the semi-colons and the declaration of A(just declare A before B to avoid writing the declaration):

template<int i, int j> 
class A { };

template<int i, int j> 
class B : public A<i, j> { };
AraK
doh, should've known that
Andy