mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-15 05:24:01 +00:00
Use pointers to iterate over symbols.
While here, don't report a dummy symbol for relocations that don't have symbols. We used to says such relocations were for the first defined symbol, but now we return end_symbols(). The llvm-readobj output change agrees with otool. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@180214 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -345,7 +345,9 @@ void MachODumper::printRelocation(const MachOObjectFile *Obj,
|
||||
if (error(RelI->getOffset(Offset))) return;
|
||||
if (error(RelI->getTypeName(RelocName))) return;
|
||||
if (error(RelI->getSymbol(Symbol))) return;
|
||||
if (error(Symbol.getName(SymbolName))) return;
|
||||
if (symbol_iterator(Symbol) != Obj->end_symbols() &&
|
||||
error(Symbol.getName(SymbolName)))
|
||||
return;
|
||||
|
||||
DataRefImpl DR = RelI->getRawDataRefImpl();
|
||||
macho::RelocationEntry RE = Obj->getRelocation(DR);
|
||||
|
Reference in New Issue
Block a user