From 584cb0a8c117859197b29cb88e85455e4476a9e4 Mon Sep 17 00:00:00 2001 From: Reid Spencer Date: Thu, 16 Dec 2004 23:04:20 +0000 Subject: For PR351: * removeFile() -> sys::Path::destroyFile() * remove extraneous toString() calls * convert local variables representing path names from std::string to sys::Path * Use sys::Path objects with FileRemove instead of std::string * Use sys::Path methods for construction of path names llvm-svn: 19001 --- llvm/tools/bugpoint/OptimizerDriver.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'llvm/tools/bugpoint/OptimizerDriver.cpp') diff --git a/llvm/tools/bugpoint/OptimizerDriver.cpp b/llvm/tools/bugpoint/OptimizerDriver.cpp index d141bd0dabe..709eff37e46 100644 --- a/llvm/tools/bugpoint/OptimizerDriver.cpp +++ b/llvm/tools/bugpoint/OptimizerDriver.cpp @@ -143,7 +143,7 @@ bool BugDriver::runPasses(const std::vector &Passes, // If we are supposed to delete the bytecode file or if the passes crashed, // remove it now. This may fail if the file was never created, but that's ok. if (DeleteOutput || !ExitedOK) - removeFile(OutputFilename); + sys::Path(OutputFilename).destroyFile(); if (!Quiet) { if (ExitedOK) @@ -194,6 +194,6 @@ Module *BugDriver::runPassesOn(Module *M, << BytecodeResult << "'!\n"; exit(1); } - removeFile(BytecodeResult); // No longer need the file on disk + sys::Path(BytecodeResult).destroyFile(); // No longer need the file on disk return Ret; } -- cgit v1.2.3