[GIT] ppl/ppl(master): Fixed implementation defined implicit cast.

Module: ppl/ppl Branch: master Commit: aea1d036a659bb31d25e382a7e215a59e3e557da URL: http://www.cs.unipr.it/git/gitweb.cgi?p=ppl/ppl.git;a=commit;h=aea1d036a659b...
Author: Abramo Bagnara abramo.bagnara@gmail.com Date: Fri Feb 24 12:34:21 2012 +0100
Fixed implementation defined implicit cast. Detected by ECLAIR service utypflag.
---
src/Linear_Form.templates.hh | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/Linear_Form.templates.hh b/src/Linear_Form.templates.hh index b2305f0..aa52658 100644 --- a/src/Linear_Form.templates.hh +++ b/src/Linear_Form.templates.hh @@ -422,11 +422,11 @@ Linear_Form<C>::relative_error(
C error_propagator; // We assume that f_base is a power of 2. - int power = msb_position(f_base) * (-f_mantissa_bits); - analyzer_format lb = -static_cast<analyzer_format>(ldexp(1.0, power)); + int power = static_cast<int>(msb_position(f_base) * f_mantissa_bits); + analyzer_format lb = static_cast<analyzer_format>(ldexp(1.0, -power));
- error_propagator.build(i_constraint(GREATER_OR_EQUAL, lb), - i_constraint(LESS_OR_EQUAL, -lb)); + error_propagator.build(i_constraint(GREATER_OR_EQUAL, -lb), + i_constraint(LESS_OR_EQUAL, lb));
// Handle the inhomogeneous term. const C* current_term = &inhomogeneous_term();
participants (1)
-
Abramo Bagnara