aboutsummaryrefslogtreecommitdiff
path: root/include/Support/MathExtras.h
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2003-11-16 20:21:15 +0000
committerChris Lattner <sabre@nondot.org>2003-11-16 20:21:15 +0000
commit8b70b78ba489b090d9866e6a4084ab1e8613b527 (patch)
treec3e137b779b119b92587950176b457381132b18f /include/Support/MathExtras.h
parentf3b2410bc4c098c0f27f689c797a539d6ef8a09e (diff)
Fixes for PR114: Thanks to Reid Spencer!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10029 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/Support/MathExtras.h')
-rw-r--r--include/Support/MathExtras.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/Support/MathExtras.h b/include/Support/MathExtras.h
index 74958fbc35..125aff3b9f 100644
--- a/include/Support/MathExtras.h
+++ b/include/Support/MathExtras.h
@@ -28,7 +28,7 @@ inline unsigned log2(uint64_t C) {
inline bool isPowerOf2(int64_t C, unsigned &getPow) {
if (C < 0) C = -C;
if (C > 0 && C == (C & ~(C - 1))) {
- getPow = log2((uint64_t)C);
+ getPow = log2(static_cast<uint64_t>(C));
return true;
}