mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-02 11:44:28 +00:00
15 lines
461 B
Rust
15 lines
461 B
Rust
//@ run-pass
|
|
//@ compile-flags: -C overflow-checks=on
|
|
//@ ignore-emscripten no threads support
|
|
//@ needs-unwind
|
|
|
|
use std::thread;
|
|
|
|
fn main() {
|
|
assert!(thread::spawn(|| i8::MIN.abs()).join().is_err());
|
|
assert!(thread::spawn(|| i16::MIN.abs()).join().is_err());
|
|
assert!(thread::spawn(|| i32::MIN.abs()).join().is_err());
|
|
assert!(thread::spawn(|| i64::MIN.abs()).join().is_err());
|
|
assert!(thread::spawn(|| isize::MIN.abs()).join().is_err());
|
|
}
|