This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/51577] dependent name lookup finds operator in global namespace
- From: "redi at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sat, 13 Apr 2013 11:52:51 +0000
- Subject: [Bug c++/51577] dependent name lookup finds operator in global namespace
- Auto-submitted: auto-generated
- References: <bug-51577-4 at http dot gcc dot gnu dot org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51577
--- Comment #5 from Jonathan Wakely <redi at gcc dot gnu.org> 2013-04-13 11:52:51 UTC ---
(In reply to comment #4)
> (In reply to comment #3)
> > The example in PR 56943 gives a wrong-code example
>
> Could you explain why? It looks valid to me. According to my understanding, the
> free operator+ overload in global namespace is no valid candidate, but the
> member operator+ of N::A is one.
and G++ calls the global one, returning the wrong result, so it's wrong-code