[PATCH] D64257: [clangd] Added highlighting for class and enum types

Johan Vikström via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jul 9 03:04:53 PDT 2019


jvikstrom added inline comments.


================
Comment at: clang-tools-extra/clangd/SemanticHighlighting.cpp:81
   void addToken(SourceLocation Loc, const Decl *D) {
+    if (isa<CXXConstructorDecl>(D)) {
+      addToken(Loc, HighlightingKind::Class);
----------------
hokein wrote:
> nit: move this around `if (isa<RecordDecl>(D)) {` since they are related to `Class`, and we should have a comment describing the highlighting behavior of `class, constructor, and destructor`.
I don't really know what you mean with this comment after the move RecordDecl around (or rather where to put the comment and what to put in it)
I wrote a comment but don't know if that's  really helpful


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D64257





More information about the cfe-commits mailing list