diff options
| author | bors <bors@rust-lang.org> | 2024-10-17 22:18:24 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2024-10-17 22:18:24 +0000 |
| commit | d9c4b8d475360b52e6debead2cd710e9fe3c7110 (patch) | |
| tree | 581cfe0d69e1d207d6d693176ee02dc8555c333d /library/std/src/sys/pal/xous/net/mod.rs | |
| parent | 3ed6e3cc69857129c1d314daec00119ff47986ed (diff) | |
| parent | 5365b3f7be079008d7cac03b821f7c65563ee5ed (diff) | |
| download | rust-d9c4b8d475360b52e6debead2cd710e9fe3c7110.tar.gz rust-d9c4b8d475360b52e6debead2cd710e9fe3c7110.zip | |
Auto merge of #131572 - cuviper:ub-index_range, r=thomcc
Avoid superfluous UB checks in `IndexRange` `IndexRange::len` is justified as an overall invariant, and `take_prefix` and `take_suffix` are justified by local branch conditions. A few more UB-checked calls remain in cases that are only supported locally by `debug_assert!`, which won't do anything in distributed builds, so those UB checks may still be useful. We generally expect core's `#![rustc_preserve_ub_checks]` to optimize away in user's release builds, but the mere presence of that extra code can sometimes inhibit optimization, as seen in #131563.
Diffstat (limited to 'library/std/src/sys/pal/xous/net/mod.rs')
0 files changed, 0 insertions, 0 deletions
