diff options
author | Duncan P. N. Exon Smith <dexonsmith@apple.com> | 2014-07-28 21:12:19 +0000 |
---|---|---|
committer | Duncan P. N. Exon Smith <dexonsmith@apple.com> | 2014-07-28 21:12:19 +0000 |
commit | 2101a7fbcf17fd33005fa2200bfca6799291130e (patch) | |
tree | 904292f364e1ae22194450c3641374f5542538ef | |
parent | 75d94849b47dbef965d60d23f3149f8ca4e89f63 (diff) | |
download | llvm-2101a7fbcf17fd33005fa2200bfca6799291130e.zip llvm-2101a7fbcf17fd33005fa2200bfca6799291130e.tar.gz llvm-2101a7fbcf17fd33005fa2200bfca6799291130e.tar.bz2 |
llvm-uselistorder: Add -save-temps option
This is part of PR5680.
llvm-svn: 214123
-rw-r--r-- | llvm/tools/llvm-uselistorder/llvm-uselistorder.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/llvm/tools/llvm-uselistorder/llvm-uselistorder.cpp b/llvm/tools/llvm-uselistorder/llvm-uselistorder.cpp index 2d9bb12..d86b592 100644 --- a/llvm/tools/llvm-uselistorder/llvm-uselistorder.cpp +++ b/llvm/tools/llvm-uselistorder/llvm-uselistorder.cpp @@ -40,6 +40,9 @@ static cl::opt<std::string> InputFilename(cl::Positional, cl::init("-"), cl::value_desc("filename")); +static cl::opt<bool> SaveTemps("save-temps", cl::desc("Save temp files"), + cl::init(false)); + namespace { struct TempFile { @@ -89,7 +92,7 @@ bool TempFile::init(const std::string &Ext) { assert(!Vector.empty()); Filename.assign(Vector.data(), Vector.data() + Vector.size()); - Remover.setFile(Filename); + Remover.setFile(Filename, !SaveTemps); DEBUG(dbgs() << " - filename = " << Filename << "\n"); return false; } |