[lld] [llvm] [Object][ELF] Support extended header for Object Parser in ELF (PR #162288)

via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 8 01:42:24 PDT 2025


================
@@ -772,7 +779,7 @@ template <class ELFT>
 Expected<StringRef>
 ELFFile<ELFT>::getSectionStringTable(Elf_Shdr_Range Sections,
                                      WarningHandler WarnHandler) const {
-  uint32_t Index = getHeader().e_shstrndx;
+  uint32_t Index = e_shstrndx;
----------------
aokblast wrote:

Sorry, it is my bad. I forget to delete the following if condition throughtly.  I thought that we cannot call specific function like the ones with Expected<> return type in constructor originally. All other parts is safe after the assignment in create(). 

https://github.com/llvm/llvm-project/pull/162288


More information about the llvm-commits mailing list