From: Duncan Sands Date: Tue, 21 Aug 2012 16:20:37 +0000 (+0000) Subject: Pacify PVS-Studio by changing the type rather than doing a cast, a tweak X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=578d5f4b80a52906a31f1b22329bc2113b79a866;p=oota-llvm.git Pacify PVS-Studio by changing the type rather than doing a cast, a tweak suggested by David Blaikie. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@162286 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/Bitcode/BitstreamWriter.h b/include/llvm/Bitcode/BitstreamWriter.h index 65933a28e43..dea118f98ed 100644 --- a/include/llvm/Bitcode/BitstreamWriter.h +++ b/include/llvm/Bitcode/BitstreamWriter.h @@ -172,7 +172,7 @@ public: if ((uint32_t)Val == Val) return EmitVBR((uint32_t)Val, NumBits); - uint64_t Threshold = uint64_t(1U << (NumBits-1)); + uint32_t Threshold = 1U << (NumBits-1); // Emit the bits with VBR encoding, NumBits-1 bits at a time. while (Val >= Threshold) {