UpdateIndexCallbacks(FileIndex *FIndex,
ClangdServer::Callbacks *ServerCallbacks,
const ThreadsafeFS &TFS, AsyncTaskRunner *Tasks,
- bool CollectInactiveRegions)
+ bool CollectInactiveRegions,
+ const ClangdServer::Options &Opts)
: FIndex(FIndex), ServerCallbacks(ServerCallbacks),
TFS(TFS), Stdlib{std::make_shared<StdLibSet>()}, Tasks(Tasks),
- CollectInactiveRegions(CollectInactiveRegions) {}
+ CollectInactiveRegions(CollectInactiveRegions), Opts(Opts) {}
void onPreambleAST(
PathRef Path, llvm::StringRef Version, CapturedASTCtx ASTCtx,
std::shared_ptr<StdLibSet> Stdlib;
AsyncTaskRunner *Tasks;
bool CollectInactiveRegions;
+ const ClangdServer::Options &Opts;
};
class DraftStoreFS : public ThreadsafeFS {
std::make_unique<UpdateIndexCallbacks>(
DynamicIdx.get(), Callbacks, TFS,
IndexTasks ? &*IndexTasks : nullptr,
- PublishInactiveRegions));
+ PublishInactiveRegions, Opts));
// Adds an index to the stack, at higher priority than existing indexes.
auto AddIndex = [&](SymbolIndex *Idx) {
if (this->Index != nullptr) {