[clang-tools-extra] [clangd] Let DefineOutline tweak handle member functions (PR #95235)

Christian Kandeler via cfe-commits cfe-commits at lists.llvm.org
Mon Aug 26 06:44:06 PDT 2024


================
@@ -144,8 +144,13 @@ getQualification(ASTContext &Context, const DeclContext *DestContext,
   // since we stored inner-most parent first.
   std::string Result;
   llvm::raw_string_ostream OS(Result);
-  for (const auto *Parent : llvm::reverse(Parents))
+  for (const auto *Parent : llvm::reverse(Parents)) {
+    if (Parent != *Parents.rbegin() && Parent->isDependent() &&
+        Parent->getAsRecordDecl() &&
+        Parent->getAsRecordDecl()->getDescribedClassTemplate())
----------------
ckandeler wrote:

The function doesn't look expensive, and this would complicate the code, so I'd rather not.

https://github.com/llvm/llvm-project/pull/95235


More information about the cfe-commits mailing list