File tree Expand file tree Collapse file tree 2 files changed +2
-3
lines changed Expand file tree Collapse file tree 2 files changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -726,7 +726,7 @@ static bool shouldKeepInSymtab(const Defined &sym) {
726
726
// * --discard-locals is used.
727
727
// * The symbol is in a SHF_MERGE section, which is normally the reason for
728
728
// the assembler keeping the .L symbol.
729
- if (sym.getName ().startswith (" .L" ) &&
729
+ if (( sym.getName ().empty () || sym. getName (). startswith (" .L" ) ) &&
730
730
(config->discard == DiscardPolicy::Locals ||
731
731
(sym.section && (sym.section ->flags & SHF_MERGE))))
732
732
return false ;
Original file line number Diff line number Diff line change @@ -733,8 +733,7 @@ Expected<uint32_t> ELFObjectFile<ELFT>::getSymbolFlags(DataRefImpl Sym) const {
733
733
} else if (EF.getHeader ().e_machine == ELF::EM_ARM) {
734
734
if (Expected<StringRef> NameOrErr = getSymbolName (Sym)) {
735
735
StringRef Name = *NameOrErr;
736
- // TODO Investigate why empty name symbols need to be marked.
737
- if (Name.empty () || Name.startswith (" $d" ) || Name.startswith (" $t" ) ||
736
+ if (Name.startswith (" $d" ) || Name.startswith (" $t" ) ||
738
737
Name.startswith (" $a" ))
739
738
Result |= SymbolRef::SF_FormatSpecific;
740
739
} else {
You can’t perform that action at this time.
0 commit comments