[lld] r315377 - Update for llvm change.
Rafael Espindola via llvm-commits
llvm-commits at lists.llvm.org
Tue Oct 10 15:18:16 PDT 2017
Author: rafael
Date: Tue Oct 10 15:18:16 2017
New Revision: 315377
URL: http://llvm.org/viewvc/llvm-project?rev=315377&view=rev
Log:
Update for llvm change.
Modified:
lld/trunk/ELF/InputFiles.cpp
lld/trunk/ELF/InputFiles.h
Modified: lld/trunk/ELF/InputFiles.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/InputFiles.cpp?rev=315377&r1=315376&r2=315377&view=diff
==============================================================================
--- lld/trunk/ELF/InputFiles.cpp (original)
+++ lld/trunk/ELF/InputFiles.cpp Tue Oct 10 15:18:16 2017
@@ -1014,7 +1014,7 @@ template <class ELFT> std::vector<String
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)
Modified: lld/trunk/ELF/InputFiles.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/InputFiles.h?rev=315377&r1=315376&r2=315377&view=diff
==============================================================================
--- lld/trunk/ELF/InputFiles.h (original)
+++ lld/trunk/ELF/InputFiles.h Tue Oct 10 15:18:16 2017
@@ -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; }
More information about the llvm-commits
mailing list