summaryrefslogtreecommitdiffstats
path: root/llvm/tools/llvm-size/llvm-size.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/tools/llvm-size/llvm-size.cpp')
-rw-r--r--llvm/tools/llvm-size/llvm-size.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/tools/llvm-size/llvm-size.cpp b/llvm/tools/llvm-size/llvm-size.cpp
index 0b0b00b05cf..1e88183df92 100644
--- a/llvm/tools/llvm-size/llvm-size.cpp
+++ b/llvm/tools/llvm-size/llvm-size.cpp
@@ -444,8 +444,7 @@ static bool checkMachOAndArchFlags(ObjectFile *o, StringRef file) {
static void PrintFileSectionSizes(StringRef file) {
// If file is not stdin, check that it exists.
if (file != "-") {
- bool exists;
- if (sys::fs::exists(file, exists) || !exists) {
+ if (!sys::fs::exists(file)) {
errs() << ToolName << ": '" << file << "': "
<< "No such file\n";
return;
OpenPOWER on IntegriCloud