[PATCH] D75447: [clangd] Make use of token buffers in semantic highlighting

Sam McCall via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Mar 2 12:55: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/SemanticHighlighting.cpp:162
+        [&](const syntax::Token &Tok) { return Tok.location() < Loc; });
+    assert(Tok);
+
----------------
`&& Tok->location() == Loc`, right?

(I think this would make a nice method `TokenBuffer::spelledTokenAt(SourceLocation) -> const Token*`)


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D75447





More information about the cfe-commits mailing list