remove int to bool conversion performance warning with VC

This commit is contained in:
Sébastien Loriot
2013-03-15 10:34:03 +01:00
parent 660c6b99ec
commit 2a71e01946
@@ -596,10 +596,10 @@ polynomial_subresultant_matrix(typename Polynomial_traits_d::Polynomial_d f,
// Divide through the divisor and set the correct sign
for(int i=0;i<m;i++) {
for(int j = i;j<m;j++) {
bool negate = ((n-m+i+1) & 2)>>1; // (n-m+i+1)==2 or 3 mod 4
negate=negate ^ (swapped & ((n-m+i+1)*(i+1)));
int negate = ((n-m+i+1) & 2)>>1; // (n-m+i+1)==2 or 3 mod 4
negate^=(swapped & ((n-m+i+1)*(i+1)));
//...XOR (swapped AND (n-m+i+1)* (i+1) is odd)
Ret[i][j] = idiv(Ret[i][j], negate ? -divisor : divisor);
Ret[i][j] = idiv(Ret[i][j], negate>0 ? -divisor : divisor);
}
}