[PATCH] D38032: [clangd] Serialize onDiagnosticsReady callbacks for the same file.

2017-09-20 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL313754: [clangd] Serialize onDiagnosticsReady callbacks for the same file. (authored by ibiryukov). Repository: rL LLVM https://reviews.llvm.org/D38032 Files: clang-tools-extra/trunk/clangd/ClangdSe

[PATCH] D38032: [clangd] Serialize onDiagnosticsReady callbacks for the same file.

2017-09-20 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. Thanks for the review! https://reviews.llvm.org/D38032 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D38032: [clangd] Serialize onDiagnosticsReady callbacks for the same file.

2017-09-20 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 115985. ilya-biryukov marked an inline comment as done. ilya-biryukov added a comment. - Added a comment to version map. - Fixed compilation after rebase. https://reviews.llvm.org/D38032 Files: clangd/ClangdServer.cpp clangd/ClangdServer.h clang

[PATCH] D38032: [clangd] Serialize onDiagnosticsReady callbacks for the same file.

2017-09-20 Thread Manuel Klimek via Phabricator via cfe-commits
klimek accepted this revision. klimek added a comment. This revision is now accepted and ready to land. LG Comment at: clangd/ClangdServer.h:287 + std::mutex DiagnosticsMutex; + llvm::StringMap ReportedDiagnosticVersions; }; Comment what it maps from.

[PATCH] D38032: [clangd] Serialize onDiagnosticsReady callbacks for the same file.

2017-09-20 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clangd/ClangdServer.cpp:321-324 +// FIXME(ibiryukov): get rid of '<' comparison here. In the current +// implementation diagnostics will not be reported after version counters' +// overflow. This should not happen in pr

[PATCH] D38032: [clangd] Serialize onDiagnosticsReady callbacks for the same file.

2017-09-20 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added inline comments. Comment at: clangd/ClangdServer.cpp:321-324 +// FIXME(ibiryukov): get rid of '<' comparison here. In the current +// implementation diagnostics will not be reported after version counters' +// overflow. This should not happen in practice,

[PATCH] D38032: [clangd] Serialize onDiagnosticsReady callbacks for the same file.

2017-09-19 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 115821. ilya-biryukov added a comment. - Removed an incidental `Mutex.unlock()`, a leftover from previous drafts. https://reviews.llvm.org/D38032 Files: clangd/ClangdServer.cpp clangd/ClangdServer.h clangd/DraftStore.h unittests/clangd/ClangdT

[PATCH] D38032: [clangd] Serialize onDiagnosticsReady callbacks for the same file.

2017-09-19 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. Calls to onDiagnosticsReady were done concurrently before. This sometimes led to older versions of diagnostics being reported to the user after the newer versions. https://reviews.llvm.org/D38032 Files: clangd/ClangdServer.cpp clangd/ClangdServer.h cla