summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--clang-tools-extra/clangd/index/Background.cpp2
-rw-r--r--clang-tools-extra/clangd/index/Background.h2
2 files changed, 3 insertions, 1 deletions
diff --git a/clang-tools-extra/clangd/index/Background.cpp b/clang-tools-extra/clangd/index/Background.cpp
index da96f8cad31..bfb559f13fd 100644
--- a/clang-tools-extra/clangd/index/Background.cpp
+++ b/clang-tools-extra/clangd/index/Background.cpp
@@ -43,7 +43,7 @@ BackgroundIndex::BackgroundIndex(
URISchemes(URISchemes),
IndexStorageFactory(std::move(IndexStorageFactory)) {
assert(ThreadPoolSize > 0 && "Thread pool size can't be zero.");
- assert(IndexStorageFactory && "Storage factory can not be null!");
+ assert(this->IndexStorageFactory && "Storage factory can not be null!");
while (ThreadPoolSize--) {
ThreadPool.emplace_back([this] { run(); });
// Set priority to low, since background indexing is a long running task we
diff --git a/clang-tools-extra/clangd/index/Background.h b/clang-tools-extra/clangd/index/Background.h
index 714303bf2ab..52fca242189 100644
--- a/clang-tools-extra/clangd/index/Background.h
+++ b/clang-tools-extra/clangd/index/Background.h
@@ -32,6 +32,8 @@ namespace clangd {
// operations can be called from multiple-threads concurrently.
class BackgroundIndexStorage {
public:
+ virtual ~BackgroundIndexStorage() = default;
+
// Shards of the index are stored and retrieved independently, keyed by shard
// identifier - in practice this is a source file name
virtual llvm::Error storeShard(llvm::StringRef ShardIdentifier,
OpenPOWER on IntegriCloud