[clangd] Fixed a data race.
Summary: Calling addDocument after removeDocument could have resulted in an invalid program state (AST and Preamble for the valid document could have been incorrectly removed). This commit also includes an improved CppFile::cancelRebuild implementation that allows to cancel reparse without waiting for ongoing rebuild to finish. Reviewers: krasimir, bkramer, klimek Reviewed By: bkramer Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D36397 llvm-svn: 310818
Loading
Please register or sign in to comment