Code:
LinkedList.obj : error LNK2019: unresolved external symbol "class std::basic_ostream<char,struct std::char_traits<char> > & __cdecl operator<<(class std::basic_ostream<char,struct std::char_traits<char> > &,struct LinkedList<int>::Element const &)" referenced in function _main 1>LinkedList.exe : fatal error LNK1120: 1 unresolved externals
Code:
template <class Type> class LinkedList {
public:
struct Element{
friend ostream& operator<< ( ostream &output, const typename Element &E);
};
};
template <typename Type>
ostream& operator <<(ostream& output, const typename LinkedList<Type>::Element& E){
Code:
linkedlist.cpp(38): error C2785: 'std::ostream &operator <<(std::ostream &,const LinkedList<Type>::Element &)' and '<Unknown>' have different return types
