[PATCH] D94390: [clangd] Extend find-refs to include overrides.

Haojian Wu via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Jan 20 04:22:37 PST 2021


hokein added a comment.

In D94390#2491046 <https://reviews.llvm.org/D94390#2491046>, @njames93 wrote:

> Should we be providing virtual method overrides when finding references, surely that's what query implementations is for?

yeah, go-to-implementation is designed for this purpose. However, not every LSP-client would expose a UI for go-to-implementation, we want to surface these results for these clients as well via other common features like go-to-def, find-references, hover etc.



================
Comment at: clang-tools-extra/clangd/unittests/XRefsTests.cpp:1834
 
+TEST(FindReferences, IncludeOverrides) {
+  llvm::StringRef Test =
----------------
usaxena95 wrote:
> nit: May be include tests for CRTP too.
I think CRTP is about class inheritance, while in this patch we just handle virtual methods which seems not related to CRTP.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D94390



More information about the cfe-commits mailing list