Rollup merge of #63366 - lzutao:fix-float-to-le-bytes-typo, r=Centril
doc: Fix typo in float from bytes methods Thanks @That3Percent for pointing it out. r? @Centril
This commit is contained in:
commit
1514bc1c68
@ -536,7 +536,7 @@ impl f32 {
|
||||
Self::from_bits(u32::from_be_bytes(bytes))
|
||||
}
|
||||
|
||||
/// Create a floating point value from its representation as a byte array in big endian.
|
||||
/// Create a floating point value from its representation as a byte array in little endian.
|
||||
///
|
||||
/// # Examples
|
||||
///
|
||||
@ -551,7 +551,7 @@ impl f32 {
|
||||
Self::from_bits(u32::from_le_bytes(bytes))
|
||||
}
|
||||
|
||||
/// Create a floating point value from its representation as a byte array in big endian.
|
||||
/// Create a floating point value from its representation as a byte array in native endian.
|
||||
///
|
||||
/// As the target platform's native endianness is used, portable code
|
||||
/// likely wants to use [`from_be_bytes`] or [`from_le_bytes`], as
|
||||
|
@ -549,7 +549,7 @@ impl f64 {
|
||||
Self::from_bits(u64::from_be_bytes(bytes))
|
||||
}
|
||||
|
||||
/// Create a floating point value from its representation as a byte array in big endian.
|
||||
/// Create a floating point value from its representation as a byte array in little endian.
|
||||
///
|
||||
/// # Examples
|
||||
///
|
||||
@ -564,7 +564,7 @@ impl f64 {
|
||||
Self::from_bits(u64::from_le_bytes(bytes))
|
||||
}
|
||||
|
||||
/// Create a floating point value from its representation as a byte array in big endian.
|
||||
/// Create a floating point value from its representation as a byte array in native endian.
|
||||
///
|
||||
/// As the target platform's native endianness is used, portable code
|
||||
/// likely wants to use [`from_be_bytes`] or [`from_le_bytes`], as
|
||||
|
Loading…
x
Reference in New Issue
Block a user