Missing const_iterator overload of std::vector::erase() with g++ 4.8

后端 未结 2 1429
情话喂你
情话喂你 2020-12-11 02:39

The following example will not compile using g++ 4.8.2:

#include 
#include 
using namespace std;

int main() {
    vector

        
2条回答
  •  温柔的废话
    2020-12-11 03:18

    This is a known bug in gcc: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57158

    erase requires an iterator instead of a const_iterator with current gcc's.

提交回复
热议问题