We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 3f38b99 + a028292 commit fc2837bCopy full SHA for fc2837b
src/libcore/num/f64.rs
@@ -474,11 +474,11 @@ impl f64 {
474
/// assuming that the value is finite and fits in that type.
475
///
476
/// ```
477
- /// let value = 4.6_f32;
+ /// let value = 4.6_f64;
478
/// let rounded = unsafe { value.to_int_unchecked::<u16>() };
479
/// assert_eq!(rounded, 4);
480
481
- /// let value = -128.9_f32;
+ /// let value = -128.9_f64;
482
/// let rounded = unsafe { value.to_int_unchecked::<i8>() };
483
/// assert_eq!(rounded, i8::MIN);
484
0 commit comments