aboutsummaryrefslogtreecommitdiff
path: root/tests/validation/FixedPoint.h
diff options
context:
space:
mode:
Diffstat (limited to 'tests/validation/FixedPoint.h')
-rw-r--r--tests/validation/FixedPoint.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/validation/FixedPoint.h b/tests/validation/FixedPoint.h
index 261fcd6df6..ab6f14a49b 100644
--- a/tests/validation/FixedPoint.h
+++ b/tests/validation/FixedPoint.h
@@ -768,7 +768,7 @@ struct functions
x2 = shift_right(mul(x2, three_minus_dx), 1);
}
- return (shift < 0) ? shift_left(x2, -shift >> 1) : shift_right(x2, shift >> 1);
+ return (shift < 0) ? shift_left(x2, (-shift) >> 1) : shift_right(x2, shift >> 1);
}
/** Calculate the hyperbolic tangent of a fixed point number
*