[PATCH] D92704: [clangd] Publish config file errors over LSP

Haojian Wu via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Dec 7 01:05:16 PST 2020


hokein accepted this revision.
hokein added a comment.
This revision is now accepted and ready to land.

The pre-merging bot seems to be failed on windows: https://reviews.llvm.org/harbormaster/unit/view/215879/.



================
Comment at: clang-tools-extra/clangd/ClangdServer.cpp:833
+  llvm::StringMap<std::vector<Diag>> ReportableDiagnostics;
+  auto DiagnosticHandler = [&](const llvm::SMDiagnostic &D) {
+    // Ensure we create the map entry even for note diagnostics we don't report.
----------------
I'd encode `Config` into names, `DiagnosticHandler` made me think this is a handler for clang diagnostics (without reading the context).


================
Comment at: clang-tools-extra/clangd/ClangdServer.h:366
   const ThreadsafeFS &TFS;
+  Callbacks *ServerCallbacks;
+  mutable std::mutex ConfigDiagnosticsMu;
----------------
nit: = nullptr.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D92704



More information about the cfe-commits mailing list