summaryrefslogtreecommitdiffstats
path: root/clang-tools-extra/clangd/ClangdServer.cpp
diff options
context:
space:
mode:
authorMarc-Andre Laperle <marc-andre.laperle@ericsson.com>2017-10-02 18:00:37 +0000
committerMarc-Andre Laperle <marc-andre.laperle@ericsson.com>2017-10-02 18:00:37 +0000
commitbf11424b7fcabf997c2d43c7d0d9949351588b45 (patch)
treec190b6f413ae6fe57b85fc798459daccd74411ae /clang-tools-extra/clangd/ClangdServer.cpp
parenta807660918ec33d05c39fb20fffeab84775cfcbc (diff)
downloadbcm5719-llvm-bf11424b7fcabf997c2d43c7d0d9949351588b45.tar.gz
bcm5719-llvm-bf11424b7fcabf997c2d43c7d0d9949351588b45.zip
[clangd] Handle workspace/didChangeWatchedFiles
Summary: The client can send notifications when it detects watched files have changed. This patch adds the protocol handling for this type of notification. For now, the notification will be passed down to the ClangdServer, but it will not be acted upon. However, this will become useful for the indexer to react to file changes. The events could also potentially be used to invalidate other caches (compilation database, etc). This change also updates the VSCode extension so that it sends the events. Signed-off-by: Marc-Andre Laperle <marc-andre.laperle@ericsson.com> Reviewers: ilya-biryukov, Nebiroth Subscribers: ilya-biryukov Tags: #clang-tools-extra Differential Revision: https://reviews.llvm.org/D38422 llvm-svn: 314693
Diffstat (limited to 'clang-tools-extra/clangd/ClangdServer.cpp')
-rw-r--r--clang-tools-extra/clangd/ClangdServer.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/clang-tools-extra/clangd/ClangdServer.cpp b/clang-tools-extra/clangd/ClangdServer.cpp
index 2cf2cb791eb..f5d03252422 100644
--- a/clang-tools-extra/clangd/ClangdServer.cpp
+++ b/clang-tools-extra/clangd/ClangdServer.cpp
@@ -424,3 +424,8 @@ ClangdServer::scheduleCancelRebuild(std::shared_ptr<CppFile> Resources) {
std::move(DeferredCancel));
return DoneFuture;
}
+
+void ClangdServer::onFileEvent(const DidChangeWatchedFilesParams &Params) {
+ // FIXME: Do nothing for now. This will be used for indexing and potentially
+ // invalidating other caches.
+}
OpenPOWER on IntegriCloud