From aba65b05fc5dd8649725431e38359b7fa1ab59e8 Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Sun, 25 Dec 2011 01:20:19 +0000 Subject: [PATCH] Remove unused variables. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@147261 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Object/ObjectFile.cpp | 2 +- tools/llvm-nm/llvm-nm.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/Object/ObjectFile.cpp b/lib/Object/ObjectFile.cpp index d051c03db30..b14df9af64f 100644 --- a/lib/Object/ObjectFile.cpp +++ b/lib/Object/ObjectFile.cpp @@ -58,7 +58,7 @@ ObjectFile *ObjectFile::createObjectFile(MemoryBuffer *Object) { ObjectFile *ObjectFile::createObjectFile(StringRef ObjectPath) { OwningPtr File; - if (error_code ec = MemoryBuffer::getFile(ObjectPath, File)) + if (MemoryBuffer::getFile(ObjectPath, File)) return NULL; return createObjectFile(File.take()); } diff --git a/tools/llvm-nm/llvm-nm.cpp b/tools/llvm-nm/llvm-nm.cpp index 3e159c75f41..13356f81b80 100644 --- a/tools/llvm-nm/llvm-nm.cpp +++ b/tools/llvm-nm/llvm-nm.cpp @@ -335,7 +335,7 @@ static void DumpSymbolNamesFromFile(std::string &Filename) { for (object::Archive::child_iterator i = a->begin_children(), e = a->end_children(); i != e; ++i) { OwningPtr child; - if (error_code ec = i->getAsBinary(child)) { + if (i->getAsBinary(child)) { // Try opening it as a bitcode file. OwningPtr buff(i->getBuffer()); Module *Result = 0;