What does enabling STL iterator debugging really do?

前端 未结 3 1766
日久生厌
日久生厌 2021-01-04 18:51

I\'ve enabled iterator debugging in an application by defining

_HAS_ITERATOR_DEBUGGING = 1

I was expecting this to really just check vector

3条回答
  •  隐瞒了意图╮
    2021-01-04 19:15

    As far as I understand:

    _HAS_ITERATOR_DEBUGGING will display a dialog box at run time to assert any incorrect iterator use including:

    1) Iterators used in a container after an element is erased

    2) Iterators used in vectors after a .push() or .insert() function is called

提交回复
热议问题