0

Together.cpp: Code: http://pastebin.com/yMFMKe1K Output + Compilation: Output + Compilation But, when split into the LinkedList class. CPP: http://pastebin.com/3hLYb18X H: http://pastebin.com/ibEZQ0ut main: http://pastebin.com/AmFf65KC It decides to error!Error 1 Even worse, when uncommenting the iterate function, it gives me an even scarier error! Error 2 I'm very sorry for the inconvenience caused by the bad formatting of this post. Please can I have some help. :)

Skydive
  • 25
  • 5

1 Answers1

1

Templates must be fully defined in the header file (i.e, no .cpp). Just cut & paste your implementation from your .cpp to the bottom of your header.

Quentin
  • 62,093
  • 7
  • 131
  • 191
  • 1
    Further information on this topic: [Why can templates only be implemented in the header file?](http://stackoverflow.com/questions/495021/why-can-templates-only-be-implemented-in-the-header-file) –  Jul 04 '14 at 20:30