diff options
| author | Samuel Tardieu <sam@rfc1149.net> | 2025-07-16 17:06:38 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-07-16 17:06:38 +0200 |
| commit | 37aba8388e93c9beeb092cbfa4540555d67a0af9 (patch) | |
| tree | c0bf69c71c431a85b7a2dd2a712a4342d953dd17 /compiler/rustc_llvm/llvm-wrapper | |
| parent | 9f2015d3d3884e17044be61926292f7b7a41bdc8 (diff) | |
| parent | f1b5a5638ec3aba301dc5a50daccb4c1ed69ac78 (diff) | |
| download | rust-37aba8388e93c9beeb092cbfa4540555d67a0af9.tar.gz rust-37aba8388e93c9beeb092cbfa4540555d67a0af9.zip | |
Rollup merge of #143355 - hkBst:cleanup-shift-double-bitmask, r=Mark-Simulacrum
wrapping shift: remove first bitmask and table
```rust
#[inline(always)]
pub const fn wrapping_shl(self, rhs: u32) -> Self {
// SAFETY: the masking by the bitsize of the type ensures that we do not shift
// out of bounds
unsafe {
self.unchecked_shl(rhs & (Self::BITS - 1))
}
}
```
already does the bitmask, so it seems unnecessary here.
More context: internals.rust-lang.org/t/wrapping-shift-operator-code-doing-bitmasking-twice/23167
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper')
0 files changed, 0 insertions, 0 deletions
