diff options
| author | Matthias Krüger <476013+matthiaskrgr@users.noreply.github.com> | 2025-04-09 20:23:12 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-04-09 20:23:12 +0200 |
| commit | a8b0d56f6f6b9c953d5d70e1133dd509fc8fe316 (patch) | |
| tree | c4c6e53be078d722fdcbd69ff85ae39876adfa1e | |
| parent | 78e59af9979a0ed2c5dc147bc0e90f10f1ef0248 (diff) | |
| parent | f2dee82052783ad6447d69aa26869db1f71f04cb (diff) | |
| download | rust-a8b0d56f6f6b9c953d5d70e1133dd509fc8fe316.tar.gz rust-a8b0d56f6f6b9c953d5d70e1133dd509fc8fe316.zip | |
Rollup merge of #139532 - bjoernager:master, r=tgross35
Update `u8`-to-and-from-`i8` suggestions. `u8::cast_signed` and `i8::cast_unsigned` have been stabilised, but `i8::from_ne_bytes` et al. still suggest using `as i8` or `as u8`.
| -rw-r--r-- | library/core/src/num/mod.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/library/core/src/num/mod.rs b/library/core/src/num/mod.rs index 151e128cd78..4c51fcf3b52 100644 --- a/library/core/src/num/mod.rs +++ b/library/core/src/num/mod.rs @@ -99,8 +99,8 @@ macro_rules! i8_xe_bytes_doc { **Note**: This function is meaningless on `i8`. Byte order does not exist as a concept for byte-sized integers. This function is only provided in symmetry -with larger integer types. You can cast from and to `u8` using `as i8` and `as -u8`. +with larger integer types. You can cast from and to `u8` using +[`cast_signed`](u8::cast_signed) and [`cast_unsigned`](Self::cast_unsigned). " }; |
