Kaydet (Commit) 4b71bb35 authored tarafından Norbert Thiebaud's avatar Norbert Thiebaud

work around windows whining

Change-Id: If2922bca25c93edc25e1171001def8ce3011cf4c
üst b564162d
...@@ -128,10 +128,11 @@ void rational_ReduceInaccurate(boost::rational<sal_Int64>& rRational, unsigned n ...@@ -128,10 +128,11 @@ void rational_ReduceInaccurate(boost::rational<sal_Int64>& rRational, unsigned n
DBG_ASSERT(nSignificantBits<65, "More than 64 bit of significance is overkill!"); DBG_ASSERT(nSignificantBits<65, "More than 64 bit of significance is overkill!");
// How much bits can we lose? // How much bits can we lose?
const int nMulBitsToLose = std::max( ( impl_NumberOfBits( nMul ) - int( nSignificantBits ) ), 0 ); const int nMulBitsToLose = impl_NumberOfBits( nMul ) - int( nSignificantBits );
const int nDivBitsToLose = std::max( ( impl_NumberOfBits( nDiv ) - int( nSignificantBits ) ), 0 ); const int nDivBitsToLose = impl_NumberOfBits( nDiv ) - int( nSignificantBits );
const int nToLose = std::min( nMulBitsToLose, nDivBitsToLose ); int nToLose = nMulBitsToLose < nDivBitsToLose ? nMulBitsToLose : nDivBitsToLose;
nToLose = nToLose < 0 ? 0 : nToLose;
// Remove the bits // Remove the bits
nMul >>= nToLose; nMul >>= nToLose;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment