As of GCC 4.9.2, it's now possible to compile C++11 code that inserts or erases container elements via a const_iterator.
I can see how it makes sense for insert to accept a const_iterator, but I'm struggling to understand why it makes sense to allow erasure via a const_iterator.
This issue has been discussed previously, but I haven't seen an explanation of the rationale behind the change in behaviour.
The best answer I can think of is that the purpose of the change was to make the behaviour of const_iterator analogous to that of a const T*.
Clearly a major reason for allowing delete with const T* is to enable declarations such as:
const T* x = new T; .... delete x;
However, it also permits the following less desirable behaviour:
int** x = new int*; x = new int; const int* y = x; delete y; // deletes x via a pointer-to-const
and I'm struggling to see why it's a good thing for const_iterator to emulate this behaviour.