File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -263,7 +263,7 @@ impl Float for f32 {
263263 // Since we do not support sNaN in Rust yet, we do not need to handle them.
264264 // FIXME(nagisa): due to https://bugs.llvm.org/show_bug.cgi?id=33303 we canonicalize by
265265 // multiplying by 1.0. Should switch to the `canonicalize` when it works.
266- ( if self < other || self . is_nan ( ) { other } else { self } ) * 1.0
266+ ( if self . is_nan ( ) || self < other { other } else { self } ) * 1.0
267267 }
268268
269269 /// Returns the minimum of the two numbers.
@@ -277,6 +277,6 @@ impl Float for f32 {
277277 // Since we do not support sNaN in Rust yet, we do not need to handle them.
278278 // FIXME(nagisa): due to https://bugs.llvm.org/show_bug.cgi?id=33303 we canonicalize by
279279 // multiplying by 1.0. Should switch to the `canonicalize` when it works.
280- ( if self < other || other. is_nan ( ) { self } else { other } ) * 1.0
280+ ( if other. is_nan ( ) || self < other { self } else { other } ) * 1.0
281281 }
282282}
Original file line number Diff line number Diff line change @@ -261,7 +261,7 @@ impl Float for f64 {
261261 // Since we do not support sNaN in Rust yet, we do not need to handle them.
262262 // FIXME(nagisa): due to https://bugs.llvm.org/show_bug.cgi?id=33303 we canonicalize by
263263 // multiplying by 1.0. Should switch to the `canonicalize` when it works.
264- ( if self < other || self . is_nan ( ) { other } else { self } ) * 1.0
264+ ( if self . is_nan ( ) || self < other { other } else { self } ) * 1.0
265265 }
266266
267267 /// Returns the minimum of the two numbers.
@@ -275,6 +275,6 @@ impl Float for f64 {
275275 // Since we do not support sNaN in Rust yet, we do not need to handle them.
276276 // FIXME(nagisa): due to https://bugs.llvm.org/show_bug.cgi?id=33303 we canonicalize by
277277 // multiplying by 1.0. Should switch to the `canonicalize` when it works.
278- ( if self < other || other. is_nan ( ) { self } else { other } ) * 1.0
278+ ( if other. is_nan ( ) || self < other { self } else { other } ) * 1.0
279279 }
280280}
You can’t perform that action at this time.
0 commit comments