This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/41792] overloading the address operator confuses the standard containers
- From: "paolo dot carlini at oracle dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 22 Oct 2009 18:07:14 -0000
- Subject: [Bug libstdc++/41792] overloading the address operator confuses the standard containers
- References: <bug-41792-8718@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #1 from paolo dot carlini at oracle dot com 2009-10-22 18:07 -------
Didn't I reply to this issue already on the mailing list, recently? Anyway,
within C++03 the & is supposed to not be overloaded, you can take it for
example from the lines in the standard about allocator::address. Also, about
list specifically, when we recently we did a change involving & in a member
function, provided by LWG chair Howard Hinnant, we carefully reconsidered this
issue, and verified that within of C++03 we are fine. As an extenssion, I agree
it would make sense to have something like boost::address_of in such cases
(whose implementation, as far I remember, it's just *ugly*)
--
paolo dot carlini at oracle dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
Severity|normal |enhancement
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41792