1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-25 04:02:41 +01:00

GCC objects to the two sides of a conditional expression having different enum

types, but they're just getting converted to unsigned anyway, so cast first
(and ask questions later).

llvm-svn: 122377
This commit is contained in:
Matt Beaumont-Gay 2010-12-21 23:43:23 +00:00
parent 1ee218de0e
commit b03146b50a

View File

@ -765,8 +765,8 @@ public:
// Note that there is no longer any semantic difference between these two
// relocation types from the linkers point of view, this is done solely
// for pedantic compatibility with 'as'.
Type = A_SD->isExternal() ? macho::RIT_Difference :
macho::RIT_Generic_LocalDifference;
Type = A_SD->isExternal() ? (unsigned)macho::RIT_Difference :
(unsigned)macho::RIT_Generic_LocalDifference;
Value2 = getSymbolAddress(B_SD, Layout);
FixedValue -= getSectionAddress(B_SD->getFragment()->getParent());
}