Investigate D110386 failures even further
authorKirill Bobyrev <kbobyrev@google.com>
Tue, 28 Sep 2021 10:02:13 +0000 (12:02 +0200)
committerKirill Bobyrev <kbobyrev@google.com>
Tue, 28 Sep 2021 10:02:13 +0000 (12:02 +0200)
clang-tools-extra/clangd/Headers.h

index 900b779927e276b49417ce4f5b29d2292123da43..5b7ffa5de4cf91ffa148e5cb7c7c7175340d2b48 100644 (file)
@@ -143,8 +143,15 @@ public:
   std::vector<Inclusion> MainFileIncludes;
 
   std::string dump() {
-    return "RealPathNames: " +
-           llvm::join(RealPathNames.begin(), RealPathNames.end(), ", ");
+    std::string Result =
+        "RealPathNames: " +
+        llvm::join(RealPathNames.begin(), RealPathNames.end(), ", ");
+    Result += "; NameToIndex: ";
+    for (const auto &NameIndex : NameToIndex) {
+      Result += NameIndex.first().str() + ' ' +
+                std::to_string(static_cast<unsigned>(NameIndex.second)) + ", ";
+    }
+    return Result;
   }
 
 private: