[llvm-commits] [llvm] r132538 - /llvm/trunk/lib/Support/FoldingSet.cpp
Zhongxing Xu
xuzhongxing at foxmail.com
Fri Jun 3 01:29:51 PDT 2011
Author: zhongxingxu
Date: Fri Jun 3 03:29:51 2011
New Revision: 132538
URL: http://llvm.org/viewvc/llvm-project?rev=132538&view=rev
Log:
singed int causes signed extension, which contradicts the intention to pick up
integers with high 32 bits being zero.
Modified:
llvm/trunk/lib/Support/FoldingSet.cpp
Modified: llvm/trunk/lib/Support/FoldingSet.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/FoldingSet.cpp?rev=132538&r1=132537&r2=132538&view=diff
==============================================================================
--- llvm/trunk/lib/Support/FoldingSet.cpp (original)
+++ llvm/trunk/lib/Support/FoldingSet.cpp Fri Jun 3 03:29:51 2011
@@ -92,7 +92,7 @@
}
void FoldingSetNodeID::AddInteger(unsigned long long I) {
AddInteger(unsigned(I));
- if ((uint64_t)(int)I != I)
+ if ((uint64_t)(unsigned)I != I)
Bits.push_back(unsigned(I >> 32));
}
More information about the llvm-commits
mailing list