[clang-tools-extra] b1309a1 - [clangd] Print the Spelled RefKind.

Haojian Wu via cfe-commits cfe-commits at lists.llvm.org
Thu Feb 13 04:28:29 PST 2020


Author: Haojian Wu
Date: 2020-02-13T13:28:11+01:00
New Revision: b1309a18ba7314332cf05a40f48db4d42a51f214

URL: https://github.com/llvm/llvm-project/commit/b1309a18ba7314332cf05a40f48db4d42a51f214
DIFF: https://github.com/llvm/llvm-project/commit/b1309a18ba7314332cf05a40f48db4d42a51f214.diff

LOG: [clangd] Print the Spelled RefKind.

Added: 
    

Modified: 
    clang-tools-extra/clangd/index/Ref.cpp

Removed: 
    


################################################################################
diff  --git a/clang-tools-extra/clangd/index/Ref.cpp b/clang-tools-extra/clangd/index/Ref.cpp
index 0e4605f3800d..115894ce6743 100644
--- a/clang-tools-extra/clangd/index/Ref.cpp
+++ b/clang-tools-extra/clangd/index/Ref.cpp
@@ -14,8 +14,8 @@ namespace clangd {
 llvm::raw_ostream &operator<<(llvm::raw_ostream &OS, RefKind K) {
   if (K == RefKind::Unknown)
     return OS << "Unknown";
-  static constexpr std::array<const char *, 3> Messages = {"Decl", "Def",
-                                                           "Ref"};
+  static constexpr std::array<const char *, 4> Messages = {"Decl", "Def", "Ref",
+                                                           "Spelled"};
   bool VisitedOnce = false;
   for (unsigned I = 0; I < Messages.size(); ++I) {
     if (static_cast<uint8_t>(K) & 1u << I) {


        


More information about the cfe-commits mailing list