Skip to content

Commit

Permalink
I am the ultimate dingus
Browse files Browse the repository at this point in the history
thank you @saethlin

Co-authored-by: Ben Kimock <kimockb@gmail.com>
  • Loading branch information
clarfonthey and saethlin committed Nov 5, 2023
1 parent 44cdc07 commit 4b9510f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions library/core/src/num/uint_macros.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1014,11 +1014,11 @@ macro_rules! uint_impl {
unsafe {
let lhs = self;
intrinsics::assert_unsafe_precondition!(
concat!(stringify!($SelfT), "::unchecked_shl cannot overflow"),
concat!(stringify!($SelfT), "::unchecked_shr cannot overflow"),
(rhs: u32) => rhs < <$SelfT>::BITS
);
let rhs = conv_rhs_for_unchecked_shift!($SelfT, rhs);
intrinsics::unchecked_shl(lhs, rhs)
intrinsics::unchecked_shr(lhs, rhs)
}
}

Expand Down

0 comments on commit 4b9510f

Please sign in to comment.