This revision was automatically updated to reflect the committed changes.
Closed by commit rCTE349348: [clangd] Change diskbackedstorage to be atomic
(authored by kadircet, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D55417?vs=178448&id=178449#toc
Repository:
rCTE Clang
kadircet updated this revision to Diff 178448.
kadircet marked 3 inline comments as done.
kadircet added a comment.
- Address comments
Repository:
rCTE Clang Tools Extra
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D55417/new/
https://reviews.llvm.org/D55417
Files:
clangd/index/Ba
ilya-biryukov accepted this revision.
ilya-biryukov added a comment.
This revision is now accepted and ready to land.
LGTM with a few nits
Comment at: clangd/index/BackgroundIndexStorage.cpp:39
+template
+llvm::Error writeAtomically(llvm::StringRef OutPath, WriterFunction &&Wr
kadircet updated this revision to Diff 178059.
kadircet marked 2 inline comments as done.
kadircet added a comment.
- Use creauteUniqueFile.
- Don't remove on success.
Repository:
rCTE Clang Tools Extra
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D55417/new/
https://reviews.llvm.org
ilya-biryukov added inline comments.
Comment at: clangd/index/BackgroundIndexStorage.cpp:42
+ llvm::Twine TempPath(OutPath, ".tmp.");
+ TempPath.concat(std::to_string(rand()));
+ std::error_code EC;
There's a helper in LLVM that will do this, `llvm::createUniq
kadircet updated this revision to Diff 177181.
kadircet marked 2 inline comments as done.
kadircet added a comment.
- Address comments
Repository:
rCTE Clang Tools Extra
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D55417/new/
https://reviews.llvm.org/D55417
Files:
clangd/index/Ba