tom-anders created this revision. tom-anders added a reviewer: sammccall. Herald added subscribers: kadircet, arphaman. Herald added a project: All. tom-anders requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang-tools-extra.
Since https://reviews.llvm.org/D135506 it's sufficient to only drop UsingDecl here Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D135536 Files: clang-tools-extra/clangd/Hover.cpp Index: clang-tools-extra/clangd/Hover.cpp =================================================================== --- clang-tools-extra/clangd/Hover.cpp +++ clang-tools-extra/clangd/Hover.cpp @@ -1017,7 +1017,7 @@ // which isn't really useful for Hover. So use the other one, // which in this example would be the actual declaration of foo. if (Candidates.size() <= 2) { - if (llvm::isa<BaseUsingDecl>(Candidates.front())) + if (llvm::isa<UsingDecl>(Candidates.front())) return Candidates.back(); return Candidates.front(); } @@ -1029,7 +1029,7 @@ // we actually want to show the using declaration, // it's not clear which declaration to pick otherwise. auto BaseDecls = llvm::make_filter_range(Candidates, [](const NamedDecl *D) { - return llvm::isa<BaseUsingDecl>(D); + return llvm::isa<UsingDecl>(D); }); if (std::distance(BaseDecls.begin(), BaseDecls.end()) == 1) return *BaseDecls.begin();
Index: clang-tools-extra/clangd/Hover.cpp =================================================================== --- clang-tools-extra/clangd/Hover.cpp +++ clang-tools-extra/clangd/Hover.cpp @@ -1017,7 +1017,7 @@ // which isn't really useful for Hover. So use the other one, // which in this example would be the actual declaration of foo. if (Candidates.size() <= 2) { - if (llvm::isa<BaseUsingDecl>(Candidates.front())) + if (llvm::isa<UsingDecl>(Candidates.front())) return Candidates.back(); return Candidates.front(); } @@ -1029,7 +1029,7 @@ // we actually want to show the using declaration, // it's not clear which declaration to pick otherwise. auto BaseDecls = llvm::make_filter_range(Candidates, [](const NamedDecl *D) { - return llvm::isa<BaseUsingDecl>(D); + return llvm::isa<UsingDecl>(D); }); if (std::distance(BaseDecls.begin(), BaseDecls.end()) == 1) return *BaseDecls.begin();
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits