[PATCH] D134529: [C++20][Clang] P2468R2 The Equality Operator You Are Looking For
Ilya Biryukov via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Sep 27 09:22:42 PDT 2022
ilya-biryukov added a reviewer: clang-language-wg.
ilya-biryukov added a comment.
Overall LG, thanks!
The only major comment from me is that we probably want to implement the full "corresponds" check so we handle various cases mentioned in the FIXMEs.
Also adding the Language WG as reviewers in case someone else wants to take a look.
> I don't follow why this disallows the reverse #4.
It seems the trick is to pick the right type of the lookup.
The particular wording says to search <https://eel.is/c++draft/basic.lookup#class.member.lookup-1> for a name in scope rather than do a qualified lookup <https://eel.is/c++draft/basic.lookup#namespace.qual-1>.
Only the latter should look inside the qualified namespaces.
Another idea for a test: try replacing declarations of `operator!=` with `using other_ns::operator!=` in various examples and make sure that it keeps working.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D134529/new/
https://reviews.llvm.org/D134529
More information about the cfe-commits
mailing list