Skip to content

Commit

Permalink
Review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
alexcrichton committed Mar 20, 2023
1 parent 82b56d4 commit 38831bf
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions tests/all/traps.rs
Original file line number Diff line number Diff line change
Expand Up @@ -672,7 +672,7 @@ fn trap_codes() {
Trap::MemoryOutOfBounds,
);

for ty in ["i32", "i64"] {
for (ty, min) in [("i32", i32::MIN as u32 as u64), ("i64", i64::MIN as u64)] {
for op in ["rem", "div"] {
for sign in ["u", "s"] {
println!("testing {ty}.{op}_{sign}");
Expand All @@ -695,11 +695,6 @@ fn trap_codes() {
}

println!("testing {ty}.div_s INT_MIN/-1");
let min = if ty == "i32" {
0x80000000_u64
} else {
0x8000000000000000_u64
};
assert_trap_code(
&format!(
r#"
Expand Down

0 comments on commit 38831bf

Please sign in to comment.