Delagating To A Linked List Issue #2

Hello I have an issue with my book.
Here is the example.

Header File
http://pastebin.com/SghDkf48

Main
http://pastebin.com/0b9EbNQG

Output
http://pastebin.com/SvDCNYrw

I want to know why the base class variable itsPartNumber is not changing when called from the from &Part::GetPartNumber in main line 224 when the loop re-iterates but does change when the new Object is called in line 239.

I think I need to be looking how copy constructors, inheritance and pointers behave but I could just do with some assistance regarding which particular area to focus on.

Thanks guys.
&Part::GetPartNumber gives you a pointer to the GetPartNumber member function of the Part class. There is no overload of the << operator for function pointers so for some reason it chooses the bool overload and outputs 1 (i.e. true).
Topic archived. No new replies allowed.