Update for llvm change.

llvm-svn: 315377
This commit is contained in:
Rafael Espindola 2017-10-10 22:18:16 +00:00
parent 8f1f7b1442
commit ae5e9ed422
2 changed files with 2 additions and 2 deletions

View File

@ -1014,7 +1014,7 @@ template <class ELFT> std::vector<StringRef> LazyObjFile::getElfSymbols() {
typedef typename ELFT::Sym Elf_Sym;
typedef typename ELFT::SymRange Elf_Sym_Range;
const ELFFile<ELFT> Obj(this->MB.getBuffer());
ELFFile<ELFT> Obj = check(ELFFile<ELFT>::create(this->MB.getBuffer()));
ArrayRef<Elf_Shdr> Sections = check(Obj.sections(), toString(this));
for (const Elf_Shdr &Sec : Sections) {
if (Sec.sh_type != SHT_SYMTAB)

View File

@ -128,7 +128,7 @@ public:
}
llvm::object::ELFFile<ELFT> getObj() const {
return llvm::object::ELFFile<ELFT>(MB.getBuffer());
return check(llvm::object::ELFFile<ELFT>::create(MB.getBuffer()));
}
StringRef getStringTable() const { return StringTable; }