3 ms·
This is a noob mistake, not a huge mystery. It's not always wrong to store raw pointers to STL container elements, but if you do then you must take care of real
by wakawaka28 3y ago
This is a noob mistake, not a huge mystery. It's not always wrong to store raw pointers to STL container elements, but if you do then you must take care of reallocations.
If you find storing pointers to elements too perilous, you should probably just make a container of pointers instead.
- D13Fd 3y ago> This is a noob mistake, not a huge mystery. The interesting part is why it worked in VS2013 but failed in VS2022.
- wakawaka28 3y ago>The interesting part is why it worked in VS2013 but failed in VS2022. I thought the explanation he came up with was interesting but such a change could have easily been brought about by changes to reallocation parameters in the implementation.
- deleted 3y ago[deleted]