ErrorOr<StringRef> getSectionStringTable(Elf_Shdr_Range Sections) const;
const Elf_Ehdr *getHeader() const { return Header; }
- ErrorOr<uint32_t> getSectionIndex(const Elf_Sym *Sym, const Elf_Shdr *SymTab,
- ArrayRef<Elf_Word> ShndxTable) const;
ErrorOr<uint32_t> getSectionIndex(const Elf_Sym *Sym, Elf_Sym_Range Syms,
ArrayRef<Elf_Word> ShndxTable) const;
ErrorOr<const Elf_Shdr *> getSection(const Elf_Sym *Sym,
return ShndxTable[Index];
}
-template <class ELFT>
-ErrorOr<uint32_t>
-ELFFile<ELFT>::getSectionIndex(const Elf_Sym *Sym, const Elf_Shdr *SymTab,
- ArrayRef<Elf_Word> ShndxTable) const {
- auto SymsOrErr = symbols(SymTab);
- if (std::error_code EC = SymsOrErr.getError())
- return EC;
- return getSectionIndex(Sym, *SymsOrErr, ShndxTable);
-}
-
template <class ELFT>
ErrorOr<uint32_t>
ELFFile<ELFT>::getSectionIndex(const Elf_Sym *Sym, Elf_Sym_Range Syms,