[libclang] Bury dead TemporaryFiles

Summary:
AllocatedCXCodeCompleteResults::TemporaryFiles have turned into zombies.
Seven years ago they used to do their job during [[ 313e26c4e8/tools/CIndex/CIndexCodeCompletion.cpp (diff-02d3e692ad507b10af9458b775c5750bL261) | file remapping]], but now they are created just to be torn down in the destructor.

Reviewers: bkramer

Reviewed By: bkramer

Subscribers: cfe-commits

Differential Revision: https://reviews.llvm.org/D31288

llvm-svn: 298697
This commit is contained in:
Krasimir Georgiev 2017-03-24 09:49:54 +00:00
parent af4adfa3ad
commit c4d5c25737
1 changed files with 0 additions and 6 deletions

View File

@ -270,10 +270,6 @@ struct AllocatedCXCodeCompleteResults : public CXCodeCompleteResults {
/// \brief Source manager, used for diagnostics.
IntrusiveRefCntPtr<SourceManager> SourceMgr;
/// \brief Temporary files that should be removed once we have finished
/// with the code-completion results.
std::vector<std::string> TemporaryFiles;
/// \brief Temporary buffers that will be deleted once we have finished with
/// the code-completion results.
SmallVector<const llvm::MemoryBuffer *, 1> TemporaryBuffers;
@ -335,8 +331,6 @@ AllocatedCXCodeCompleteResults::~AllocatedCXCodeCompleteResults() {
llvm::DeleteContainerPointers(DiagnosticsWrappers);
delete [] Results;
for (unsigned I = 0, N = TemporaryFiles.size(); I != N; ++I)
llvm::sys::fs::remove(TemporaryFiles[I]);
for (unsigned I = 0, N = TemporaryBuffers.size(); I != N; ++I)
delete TemporaryBuffers[I];