Update for llvm api change.

llvm-svn: 199327
This commit is contained in:
Rafael Espindola 2014-01-15 19:38:01 +00:00
parent 63da295045
commit 0de92d53a1
1 changed files with 3 additions and 3 deletions

View File

@ -253,10 +253,10 @@ DefinedAtom::Merge getMerge(const coff_aux_section_definition *auxsym) {
FileCOFF::FileCOFF(std::unique_ptr<MemoryBuffer> mb, error_code &ec)
: File(mb->getBufferIdentifier(), kindObject), _ordinal(0) {
OwningPtr<llvm::object::Binary> bin;
ec = llvm::object::createBinary(mb.release(), bin);
if (ec)
auto binaryOrErr = llvm::object::createBinary(mb.release());
if ((ec = binaryOrErr.getError()))
return;
OwningPtr<llvm::object::Binary> bin(binaryOrErr.get());
_obj.reset(dyn_cast<const llvm::object::COFFObjectFile>(bin.get()));
if (!_obj) {