Skip to content

Commit d06af7a

Browse files
committed
Revert "[clangd] Remove unused private field 'Opts' in UpdateIndexCallbacks (NFC)"
This reverts commit c4fa97f.
1 parent bc8c3f4 commit d06af7a

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

clang-tools-extra/clangd/ClangdServer.cpp

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,10 +67,11 @@ struct UpdateIndexCallbacks : public ParsingCallbacks {
6767
UpdateIndexCallbacks(FileIndex *FIndex,
6868
ClangdServer::Callbacks *ServerCallbacks,
6969
const ThreadsafeFS &TFS, AsyncTaskRunner *Tasks,
70-
bool CollectInactiveRegions)
70+
bool CollectInactiveRegions,
71+
const ClangdServer::Options &Opts)
7172
: FIndex(FIndex), ServerCallbacks(ServerCallbacks),
7273
TFS(TFS), Stdlib{std::make_shared<StdLibSet>()}, Tasks(Tasks),
73-
CollectInactiveRegions(CollectInactiveRegions) {}
74+
CollectInactiveRegions(CollectInactiveRegions), Opts(Opts) {}
7475

7576
void onPreambleAST(
7677
PathRef Path, llvm::StringRef Version, CapturedASTCtx ASTCtx,
@@ -163,6 +164,7 @@ struct UpdateIndexCallbacks : public ParsingCallbacks {
163164
std::shared_ptr<StdLibSet> Stdlib;
164165
AsyncTaskRunner *Tasks;
165166
bool CollectInactiveRegions;
167+
const ClangdServer::Options &Opts;
166168
};
167169

168170
class DraftStoreFS : public ThreadsafeFS {
@@ -227,7 +229,7 @@ ClangdServer::ClangdServer(const GlobalCompilationDatabase &CDB,
227229
std::make_unique<UpdateIndexCallbacks>(
228230
DynamicIdx.get(), Callbacks, TFS,
229231
IndexTasks ? &*IndexTasks : nullptr,
230-
PublishInactiveRegions));
232+
PublishInactiveRegions, Opts));
231233
// Adds an index to the stack, at higher priority than existing indexes.
232234
auto AddIndex = [&](SymbolIndex *Idx) {
233235
if (this->Index != nullptr) {

0 commit comments

Comments
 (0)