mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-11-01 15:11:24 +00:00
Speculative fix the mask constants to be of type uintptr_t. I don't know of any case where the old form was incorrect, but I'm more confident that such cases don't exist in this version.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166031 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
afac0478f4
commit
82e9bc2f57
@ -306,8 +306,8 @@ public:
|
||||
assert(E <= size() && "Attempted to set out-of-bounds range!");
|
||||
if (I == E) return *this;
|
||||
if (isSmall()) {
|
||||
uintptr_t EMask = 1 << E;
|
||||
uintptr_t IMask = 1 << I;
|
||||
uintptr_t EMask = ((uintptr_t)1) << E;
|
||||
uintptr_t IMask = ((uintptr_t)1) << I;
|
||||
uintptr_t Mask = EMask - IMask;
|
||||
setSmallBits(getSmallBits() | Mask);
|
||||
} else
|
||||
@ -337,8 +337,8 @@ public:
|
||||
assert(E <= size() && "Attempted to reset out-of-bounds range!");
|
||||
if (I == E) return *this;
|
||||
if (isSmall()) {
|
||||
uintptr_t EMask = 1 << E;
|
||||
uintptr_t IMask = 1 << I;
|
||||
uintptr_t EMask = ((uintptr_t)1) << E;
|
||||
uintptr_t IMask = ((uintptr_t)1) << I;
|
||||
uintptr_t Mask = EMask - IMask;
|
||||
setSmallBits(getSmallBits() & ~Mask);
|
||||
} else
|
||||
|
Loading…
Reference in New Issue
Block a user