[PATCH] D117037: [clang][CodeComplete] Perform approximate member search in bases

Kadir Cetinkaya via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Jan 12 01:37:52 PST 2022


kadircet added inline comments.


================
Comment at: clang-tools-extra/clangd/unittests/CodeCompleteTests.cpp:3459
+  const std::string Code = R"cpp(
+struct Base { Base foo(); };
+
----------------
sammccall wrote:
> does this also work if the base is dependent (Base<T>)?
yes


================
Comment at: clang/lib/Sema/SemaCodeComplete.cpp:5423
+        }
+      } else {
+        for (const auto *Member : RD->lookup(CDSME->getMember())) {
----------------
sammccall wrote:
> This case seems very nearly dead. Technically it is possible to get a CXXDependentScopeMemberExpr in C using recovery expr, but I can't find a case where this is useful. Maybe drop it?
ah right, i was mostly concerned about objc records, forgetting that we only perform this in dependent contexts :D


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D117037/new/

https://reviews.llvm.org/D117037



More information about the cfe-commits mailing list