ilya-biryukov accepted this revision.
ilya-biryukov added a comment.
This revision is now accepted and ready to land.

LGTM.

We should probably also take a look at highlighting macros inside the preamble 
part of the main file.
@hokein, are you planning to do this or should we just file a bug for this for 
now?



================
Comment at: clang-tools-extra/clangd/SemanticHighlighting.cpp:38
     // visitor.
-    // FIXME: Should add highlighting to the macro definitions as well. But 
this
-    // information is not collected in ParsedAST right now.
-    for (const SourceLocation &L : AST.getMainFileExpansions())
+    for (const SourceLocation &L : AST.getMacros())
       addToken(L, HighlightingKind::Macro);
----------------
NIT: use `SourceLocation`, it's just an int, so no need to use references here.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D67264



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to