Skip to content

Commit f56c40f

Browse files
committed
Fix experiment
1 parent 2d971e6 commit f56c40f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/math/generic/ceil.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -25,15 +25,15 @@ pub fn ceil<F: Float>(x: F) -> F {
2525

2626
// Otherwise, raise an inexact exception.
2727
force_eval!(x + F::MAX);
28-
if x.is_sign_negative() {
28+
if x.is_sign_positive() {
2929
ix += m;
3030
}
3131
ix &= !m;
3232
} else {
3333
// No integer part, raise an inexact exception since truncation will happen.
3434
force_eval!(x + F::MAX);
3535

36-
if x.is_sign_positive() {
36+
if x.is_sign_negative() {
3737
return F::NEG_ZERO;
3838
} else if ix << 1 != zero {
3939
return F::ONE;

0 commit comments

Comments
 (0)