This revision was automatically updated to reflect the committed changes. Closed by commit rG2a6eedbb51fd: [clangd] Destroy context before resetting CurrentReq (authored by kadircet).
Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D77671/new/ https://reviews.llvm.org/D77671 Files: clang-tools-extra/clangd/TUScheduler.cpp Index: clang-tools-extra/clangd/TUScheduler.cpp =================================================================== --- clang-tools-extra/clangd/TUScheduler.cpp +++ clang-tools-extra/clangd/TUScheduler.cpp @@ -255,9 +255,11 @@ NextReq.reset(); } - WithContext Guard(std::move(CurrentReq->Ctx)); - // Build the preamble and let the waiters know about it. - build(std::move(*CurrentReq)); + { + WithContext Guard(std::move(CurrentReq->Ctx)); + // Build the preamble and let the waiters know about it. + build(std::move(*CurrentReq)); + } bool IsEmpty = false; { std::lock_guard<std::mutex> Lock(Mutex);
Index: clang-tools-extra/clangd/TUScheduler.cpp =================================================================== --- clang-tools-extra/clangd/TUScheduler.cpp +++ clang-tools-extra/clangd/TUScheduler.cpp @@ -255,9 +255,11 @@ NextReq.reset(); } - WithContext Guard(std::move(CurrentReq->Ctx)); - // Build the preamble and let the waiters know about it. - build(std::move(*CurrentReq)); + { + WithContext Guard(std::move(CurrentReq->Ctx)); + // Build the preamble and let the waiters know about it. + build(std::move(*CurrentReq)); + } bool IsEmpty = false; { std::lock_guard<std::mutex> Lock(Mutex);
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits