I have the beginning of a linked list class, it compiles when I have it all as one file, but separating it into multiple files gives me the error "error LNK2019: unresolved external symbol "public: __thiscall List<int>::List<int>(void)" (??0?$List@H@@QAE@XZ) referenced in function _main". I'm not sure what I'm doing wrong.
List.h
1 2 3 4 5 6 7 8 9 10 11 12 13 14
#ifndef LIST_H
#define LIST_T
template <typename T>
class List {
public:
struct Node {
T data;
Node *next;
} *head, *tail;
List();
};
#endif