mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-16 00:33:10 +00:00
Add parens to suppress an MSVC 2012 << precedence warning
It doesn't seem to like instantiating the isUInt<unsigned N> template with 6+3, and then doing <<N. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173507 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
ce98f09f53
commit
66f1f30725
@ -65,7 +65,7 @@ inline bool isShiftedInt(int64_t x) {
|
|||||||
/// isUInt - Checks if an unsigned integer fits into the given bit width.
|
/// isUInt - Checks if an unsigned integer fits into the given bit width.
|
||||||
template<unsigned N>
|
template<unsigned N>
|
||||||
inline bool isUInt(uint64_t x) {
|
inline bool isUInt(uint64_t x) {
|
||||||
return N >= 64 || x < (UINT64_C(1)<<N);
|
return N >= 64 || x < (UINT64_C(1)<<(N));
|
||||||
}
|
}
|
||||||
// Template specializations to get better code for common cases.
|
// Template specializations to get better code for common cases.
|
||||||
template<>
|
template<>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user