Check output of checked_div in std_example

This commit is contained in:
bjorn3 2023-02-18 16:40:06 +01:00
parent a7c0cfc113
commit 90a7ee6c70

View File

@ -58,8 +58,8 @@ fn main() {
assert_eq!(0b0000000000000000000000000010000000000000000000000000000000000000_0000000000000000000000000000000000001000000000000000000010000000u128.trailing_zeros(), 7);
assert_eq!(core::intrinsics::saturating_sub(0, -170141183460469231731687303715884105728i128), 170141183460469231731687303715884105727i128);
let _d = 0i128.checked_div(2i128);
let _d = 0u128.checked_div(2u128);
assert!(0i128.checked_div(2i128).is_some());
assert!(0u128.checked_div(2u128).is_some());
assert_eq!(1u128 + 2, 3);
assert_eq!(0b100010000000000000000000000000000u128 >> 10, 0b10001000000000000000000u128);