i have two header files
LinkedList.h
template <class Object>
class List
{....}
template <class Object>
class ListItr
{...}
template <class Object>
class ListNode
{...}
and other is Stack.h
template<class object>
class Stack
{...}
everything seems like ok but when i tired them in test.cpp like
#include "LinkedList.h"
#include "Stack.h"
#include <iostream>
using namespace st;
int main()
{
List<char> tes;
.....
}
it gives an error like and fot every function of List class
undefined reference to `List<char>::List()'
i dont know where i am wrong??:motz:
LinkedList.h
template <class Object>
class List
{....}
template <class Object>
class ListItr
{...}
template <class Object>
class ListNode
{...}
and other is Stack.h
template<class object>
class Stack
{...}
everything seems like ok but when i tired them in test.cpp like
#include "LinkedList.h"
#include "Stack.h"
#include <iostream>
using namespace st;
int main()
{
List<char> tes;
.....
}
it gives an error like and fot every function of List class
undefined reference to `List<char>::List()'
i dont know where i am wrong??:motz: