Skip to content

Commit

Permalink
Auto merge of #3428 - rust-lang:rustup-2024-03-30, r=RalfJung
Browse files Browse the repository at this point in the history
Automatic Rustup
  • Loading branch information
bors committed Mar 30, 2024
2 parents 680cec0 + da96bba commit 4d0b9c2
Show file tree
Hide file tree
Showing 7 changed files with 1 addition and 9 deletions.
2 changes: 1 addition & 1 deletion rust-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
760e567af5398a0d8c512f904e551e1f38e00d79
69fa40cb48384fad7930dce2d9a20d18fe4d1b51
2 changes: 0 additions & 2 deletions tests/fail/intrinsics/unchecked_add1.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#![feature(unchecked_math)]

fn main() {
// MAX overflow
let _val = unsafe { 40000u16.unchecked_add(30000) }; //~ ERROR: overflow executing `unchecked_add`
Expand Down
2 changes: 0 additions & 2 deletions tests/fail/intrinsics/unchecked_add2.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#![feature(unchecked_math)]

fn main() {
// MIN overflow
let _val = unsafe { (-30000i16).unchecked_add(-8000) }; //~ ERROR: overflow executing `unchecked_add`
Expand Down
1 change: 0 additions & 1 deletion tests/fail/intrinsics/unchecked_mul1.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(unchecked_math)]
fn main() {
// MAX overflow
let _val = unsafe { 300u16.unchecked_mul(250u16) }; //~ ERROR: overflow executing `unchecked_mul`
Expand Down
1 change: 0 additions & 1 deletion tests/fail/intrinsics/unchecked_mul2.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(unchecked_math)]
fn main() {
// MIN overflow
let _val = unsafe { 1_000_000_000i32.unchecked_mul(-4) }; //~ ERROR: overflow executing `unchecked_mul`
Expand Down
1 change: 0 additions & 1 deletion tests/fail/intrinsics/unchecked_sub1.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(unchecked_math)]
fn main() {
// MIN overflow
let _val = unsafe { 14u32.unchecked_sub(22) }; //~ ERROR: overflow executing `unchecked_sub`
Expand Down
1 change: 0 additions & 1 deletion tests/fail/intrinsics/unchecked_sub2.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(unchecked_math)]
fn main() {
// MAX overflow
let _val = unsafe { 30000i16.unchecked_sub(-7000) }; //~ ERROR: overflow executing `unchecked_sub`
Expand Down

0 comments on commit 4d0b9c2

Please sign in to comment.