mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-29 10:13:54 +00:00
Normalise BITS
in UI test
This commit is contained in:
parent
b484e584ec
commit
7dda2c4218
@ -140,13 +140,13 @@ warning: this arithmetic operation will overflow
|
||||
--> $DIR/lint-exceeding-bitshifts.rs:77:15
|
||||
|
|
||||
LL | let n = 1_isize << BITS;
|
||||
| ^^^^^^^^^^^^^^^ attempt to shift left by `64_usize`, which would overflow
|
||||
| ^^^^^^^^^^^^^^^ attempt to shift left by `%BITS%`, which would overflow
|
||||
|
||||
warning: this arithmetic operation will overflow
|
||||
--> $DIR/lint-exceeding-bitshifts.rs:78:15
|
||||
|
|
||||
LL | let n = 1_usize << BITS;
|
||||
| ^^^^^^^^^^^^^^^ attempt to shift left by `64_usize`, which would overflow
|
||||
| ^^^^^^^^^^^^^^^ attempt to shift left by `%BITS%`, which would overflow
|
||||
|
||||
warning: 24 warnings emitted
|
||||
|
||||
|
@ -140,13 +140,13 @@ warning: this arithmetic operation will overflow
|
||||
--> $DIR/lint-exceeding-bitshifts.rs:77:15
|
||||
|
|
||||
LL | let n = 1_isize << BITS;
|
||||
| ^^^^^^^^^^^^^^^ attempt to shift left by `64_usize`, which would overflow
|
||||
| ^^^^^^^^^^^^^^^ attempt to shift left by `%BITS%`, which would overflow
|
||||
|
||||
warning: this arithmetic operation will overflow
|
||||
--> $DIR/lint-exceeding-bitshifts.rs:78:15
|
||||
|
|
||||
LL | let n = 1_usize << BITS;
|
||||
| ^^^^^^^^^^^^^^^ attempt to shift left by `64_usize`, which would overflow
|
||||
| ^^^^^^^^^^^^^^^ attempt to shift left by `%BITS%`, which would overflow
|
||||
|
||||
warning: 24 warnings emitted
|
||||
|
||||
|
@ -140,13 +140,13 @@ warning: this arithmetic operation will overflow
|
||||
--> $DIR/lint-exceeding-bitshifts.rs:77:15
|
||||
|
|
||||
LL | let n = 1_isize << BITS;
|
||||
| ^^^^^^^^^^^^^^^ attempt to shift left by `64_usize`, which would overflow
|
||||
| ^^^^^^^^^^^^^^^ attempt to shift left by `%BITS%`, which would overflow
|
||||
|
||||
warning: this arithmetic operation will overflow
|
||||
--> $DIR/lint-exceeding-bitshifts.rs:78:15
|
||||
|
|
||||
LL | let n = 1_usize << BITS;
|
||||
| ^^^^^^^^^^^^^^^ attempt to shift left by `64_usize`, which would overflow
|
||||
| ^^^^^^^^^^^^^^^ attempt to shift left by `%BITS%`, which would overflow
|
||||
|
||||
warning: 24 warnings emitted
|
||||
|
||||
|
@ -4,7 +4,7 @@
|
||||
//[opt_with_overflow_checks]compile-flags: -C overflow-checks=on -O
|
||||
// build-pass
|
||||
// ignore-pass (test emits codegen-time warnings and verifies that they are not errors)
|
||||
// normalize-stderr-test "shift left by (64|32)_usize which" -> "shift left by %BITS% which"
|
||||
// normalize-stderr-test "shift left by `(64|32)_usize`, which" -> "shift left by `%BITS%`, which"
|
||||
|
||||
#![crate_type="lib"]
|
||||
#![warn(arithmetic_overflow, const_err)]
|
||||
|
Loading…
Reference in New Issue
Block a user