This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/17374] New: std::set::erase(const_iterator) doesn't output error on compilation
- From: "romainbehar at yahoo dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 9 Sep 2004 12:14:02 -0000
- Subject: [Bug c++/17374] New: std::set::erase(const_iterator) doesn't output error on compilation
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
The following instructions compile without any warning; tested using g++ 2.95,
3.3 and 3.4.1:
std::set<int> vs;
const std::set<int>::const_iterator i = vs.begin();
vs.erase(i);
it should stop compilation with an error, such as:
" error: invalid conversion from `const int* const' to `int*' "
--
Summary: std::set::erase(const_iterator) doesn't output error on
compilation
Product: gcc
Version: 3.4.1
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: romainbehar at yahoo dot com
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17374