mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-11 11:34:02 +00:00
Don't use getSymbolNMTypeChar for implementing COFFObjectFile::getSymbolFileOffset.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193928 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
9bbc7b4e49
commit
30c8dc8c82
@ -112,10 +112,8 @@ error_code COFFObjectFile::getSymbolFileOffset(DataRefImpl Symb,
|
|||||||
const coff_section *Section = NULL;
|
const coff_section *Section = NULL;
|
||||||
if (error_code ec = getSection(symb->SectionNumber, Section))
|
if (error_code ec = getSection(symb->SectionNumber, Section))
|
||||||
return ec;
|
return ec;
|
||||||
char Type;
|
|
||||||
if (error_code ec = getSymbolNMTypeChar(Symb, Type))
|
if (symb->SectionNumber == COFF::IMAGE_SYM_UNDEFINED && symb->Value != 0)
|
||||||
return ec;
|
|
||||||
if (Type == 'U' || Type == 'w')
|
|
||||||
Result = UnknownAddressOrSize;
|
Result = UnknownAddressOrSize;
|
||||||
else if (Section)
|
else if (Section)
|
||||||
Result = Section->PointerToRawData + symb->Value;
|
Result = Section->PointerToRawData + symb->Value;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user