From: Jim Laskey Date: Wed, 6 Dec 2006 22:47:14 +0000 (+0000) Subject: Ignoring the upper 32 bits of a 64 bit constant is not a good thing. X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=a091fa861987b603669d730cce7365189744ab0f;p=oota-llvm.git Ignoring the upper 32 bits of a 64 bit constant is not a good thing. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32294 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/Support/MathExtras.h b/include/llvm/Support/MathExtras.h index e6a544dc77a..76447b21ebf 100644 --- a/include/llvm/Support/MathExtras.h +++ b/include/llvm/Support/MathExtras.h @@ -35,16 +35,16 @@ inline unsigned Lo_32(uint64_t Value) { } // is?Type - these functions produce optimal testing for integer data types. -inline bool isInt8 (int Value) { +inline bool isInt8 (int64_t Value) { return static_cast(Value) == Value; } -inline bool isUInt8 (int Value) { +inline bool isUInt8 (int64_t Value) { return static_cast(Value) == Value; } -inline bool isInt16 (int Value) { +inline bool isInt16 (int64_t Value) { return static_cast(Value) == Value; } -inline bool isUInt16(int Value) { +inline bool isUInt16(int64_t Value) { return static_cast(Value) == Value; } inline bool isInt32 (int64_t Value) {