Why is this vector iterator not incrementable?
erase invalidates the iterator. You can’t use it any more. Luckily for you, it returns an iterator that you can use: Or: Are you responsible for freeing the memory referred to by the pointers in the vector? If that’s the reason that you’re iterating (and your real program has more code that you haven’t shown, … Read more