summaryrefslogtreecommitdiffstats
path: root/tools/llvm-ar
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2013-07-05 12:44:49 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2013-07-05 12:44:49 +0000
commitef2703a1fbe6f7f2aed9bbb8f501a4b0d068886e (patch)
tree2591318932a7c56b0491fbc112214b987fb4c928 /tools/llvm-ar
parent3d4427347e5d540d22bd135535282761efb6bd6e (diff)
downloadexternal_llvm-ef2703a1fbe6f7f2aed9bbb8f501a4b0d068886e.zip
external_llvm-ef2703a1fbe6f7f2aed9bbb8f501a4b0d068886e.tar.gz
external_llvm-ef2703a1fbe6f7f2aed9bbb8f501a4b0d068886e.tar.bz2
Use simpler version of exists.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@185695 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/llvm-ar')
-rw-r--r--tools/llvm-ar/llvm-ar.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/tools/llvm-ar/llvm-ar.cpp b/tools/llvm-ar/llvm-ar.cpp
index 50de10b..5370715 100644
--- a/tools/llvm-ar/llvm-ar.cpp
+++ b/tools/llvm-ar/llvm-ar.cpp
@@ -665,8 +665,7 @@ int main(int argc, char **argv) {
ArchiveOperation Operation = parseCommandLine();
// Create or open the archive object.
- bool Exists;
- if (llvm::sys::fs::exists(ArchiveName, Exists) || !Exists) {
+ if (!llvm::sys::fs::exists(ArchiveName)) {
// Produce a warning if we should and we're creating the archive
if (!Create)
errs() << argv[0] << ": creating " << ArchiveName << "\n";