diff --git a/src/indexer.cc b/src/indexer.cc index 4c7a262c..7b7c1480 100644 --- a/src/indexer.cc +++ b/src/indexer.cc @@ -196,7 +196,14 @@ Kind getKind(const Decl *d, SymbolKind &kind) { // ccls extension kind = SymbolKind::Parameter; return Kind::Var; - case Decl::Var: + case Decl::Var: { + auto vd = cast(d); + if (vd->isStaticDataMember()) { + kind = SymbolKind::Field; + return Kind::Var; + } + [[fallthrough]]; + } case Decl::Decomposition: kind = SymbolKind::Variable; return Kind::Var;