I've just converted my project to Visual Studio 2012 and ran into a "list iterators not compatible" error.
I could reduce the problematic code to the following:
std::list test; std::list::iterator end = test.end(); test.clear(); assert(test.end() == end); //fail
This fails in a freshly created project.
On http://www.cplusplus.com/reference/list/list/clear/ it's said that "All iterators, references and pointers related to this container are invalidated, except the end iterators."
Does anyone know if something has changed about that? This worked fine in VS2010...
Edited by Daniel E, 07 January 2013 - 05:14 PM.






