I am currently trying to teach myself about classes, constructors and destructors. I am writing a program that uses a dynamic array as a vector and trying to implement some of the predefined vector functions. However, when the program ends in main, the error I get is CrtIsValidHeapPointer(pUserData)and it always occurs with my destructor. I have not seen this error before, nor do I know where or how to start looking to correct it. Any and all help is greatly appreciated.
Thank you for the speedy response. It also worked the first few times as well, so I started "pushing back" numbers to test it more and started getting the error. Im not sure if it makes any difference but Im using Microsoft Visual Studio Express 2013 for Windows Desktop. I made another test of it and once it told me about a breakpoint, I clicked on the "step over" button and a new window pops up saying that no symbols loaded? Here is some of what I am getting:
C:\Users\Michael\Documents\Programming\C++\Problem Solving with C++ Eighth Edition\Programming Projects\Chapter 11 Friends- Classes\Programming Project 3\Debug\wntdll.pdb: Cannot find or open the PDB file.
C:\Windows\SysWOW64\wntdll.pdb: Cannot find or open the PDB file.
C:\Windows\wntdll.pdb: Cannot find or open the PDB file.
C:\Windows\symbols\dll\wntdll.pdb: Cannot find or open the PDB file.
C:\Windows\dll\wntdll.pdb: Cannot find or open the PDB file.