View Single Post
Old May 23rd, 2006, 10:24 AM   #9
grumpy
Programming Guru
 
grumpy's Avatar
 
Join Date: Jun 2005
Location: Adelaide, South Australia
Posts: 1,253
Rep Power: 5 grumpy will become famous soon enough
Add a line "using linkedListType<Type>::first;" within the declaration of class linkedStackType.

Or, alternatively, when you use first within methods of linkedStackType<Type>, instead of typing "first" type "linkedListType<Type>::first".

Better yet, avoid deriving a template class from another template class.

The reason is to do with how inheritence works when deriving a template class from another template class with a non-concrete type parameter.

Unrelated to your problem, do NOT employ "using namespace std;" within header files. If you want to use ostream in a header file, refer to it as std::ostream.
grumpy is offline   Reply With Quote