[PATCH] D74850: [clangd] Migrate Lexer usages in TypeHierarchy to TokenBuffers

Sam McCall via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Feb 20 06:49:29 PST 2020


sammccall accepted this revision.
sammccall added inline comments.
This revision is now accepted and ready to land.


================
Comment at: clang-tools-extra/clangd/XRefs.cpp:613
+      });
+  if (!NameTok)
+    return llvm::None;
----------------
I think you're trying to test if NameTok has the location you're searching for, but you'd need to check the partition point for equality.

Couldn't you just do NameTokens = spelledForExpanded(expandedTokens(NameLoc))?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D74850





More information about the cfe-commits mailing list