[Bug libstdc++/31247] std::vector::iterator::value_type is accessible
jwakely dot gcc at gmail dot com
gcc-bugzilla@gcc.gnu.org
Sun Mar 9 15:52:00 GMT 2008
------- Comment #7 from jwakely dot gcc at gmail dot com 2008-03-09 15:51 -------
Created an attachment (id=15284)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=15284&action=view)
make nested iterator typedefs private in debug mode
It's "accepts implementation-defined" not "accepts invalid" - and it's
obviously by design that GCC accepts its own implementation-defined constructs!
This patch makes the typedefs inaccessible in debug mode and fixes up a couple
of functions that refer to them directly, rather than through iterator_traits.
Tested x86_64/linux. I also tried testing with -D_GLIBCXX_DEBUG added to
testsuite_flags but got lots of spurious failures that I don't think are
related to this change (as with parallel mode testing, all the
23_containers/*/synopsis.cc tests fail in debug mode - I haven't investigated
why)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31247
More information about the Gcc-bugs
mailing list