mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-14 11:32:34 +00:00
don't use intptr_t without including it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42921 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
a79dd432b3
commit
1ff2ddda08
@ -172,7 +172,9 @@ public:
|
|||||||
/// into a StringMapEntry, return the StringMapEntry itself.
|
/// into a StringMapEntry, return the StringMapEntry itself.
|
||||||
static StringMapEntry &GetStringMapEntryFromValue(ValueTy &V) {
|
static StringMapEntry &GetStringMapEntryFromValue(ValueTy &V) {
|
||||||
StringMapEntry *EPtr = 0;
|
StringMapEntry *EPtr = 0;
|
||||||
char *Ptr = reinterpret_cast<char*>(&V) - (intptr_t)&EPtr->Val;
|
char *Ptr = reinterpret_cast<char*>(&V) -
|
||||||
|
(reinterpret_cast<char*>(&EPtr->Val) -
|
||||||
|
reinterpret_cast<char*>(EPtr));
|
||||||
return *reinterpret_cast<StringMapEntry*>(Ptr);
|
return *reinterpret_cast<StringMapEntry*>(Ptr);
|
||||||
}
|
}
|
||||||
static const StringMapEntry &GetStringMapEntryFromValue(const ValueTy &V) {
|
static const StringMapEntry &GetStringMapEntryFromValue(const ValueTy &V) {
|
||||||
|
Loading…
Reference in New Issue
Block a user