I'm not sure why I am getting these errors. I've looked all over the forums and tried everything I can think of to fix them. any help would be greatly appreciated! Also I hope this is enough info:
Error 1 error C2955: 'DoubleLinkedListInterface' : use of class template requires template argument list \doublelinkedlist.h 10
Error 2 error C2244: 'DoubleLinkedList<T>::DoubleLinkedList' : unable to match function definition to an existing declaration doublelinkedlist.cpp 7
Error 3 .cpp error C2244: 'DoubleLinkedList<T>::~DoubleLinkedList' : unable to match function definition to an existing declaration 12
1) You've already included a body for your constructor and destructor in the header file, so your definition is in there. Why are you trying to create a second definition in a cpp file?
2) Regardless, you can't split the definition of a template class between a header and cpp file in the same way as for a normal class. The entire definition has to be within the header file.
If you'll notice i'm including the DoubleLinkedListInterface in the .h. Also I'm novice at classes so I don't completely understand specifications when it comes to .h and cpp dealing with templates etc.
Also by including iostream in the .cpp a bunch of errors were eliminated. I thought i could include the iostream in the .h and then just include the .h in m .cpp and it would automatically recognize the iostream but it didn't.
"You cannot provide template definitions in cpp files, all aspects of templates must be defined in the header"
If I remove the template definitions to the .cpp by removing the template definition I get another error
4 IntelliSense: argument list for class template "DoubleLinkedList" is missing DoubleLinkedList.cpp 5