mirror of
https://github.com/rust-lang/rust
synced 2024-11-05 20:45:15 +00:00
Rollup merge of #119628 - RalfJung:duplicate-test, r=compiler-errors
remove duplicate test
This was added in ace6fc3646
where overflowing-rsh-6 differed from overflowing-rsh-5 in a feature gate, but the feature has since been stabilized, making the tests 100% identical.
Most of these tests in numbers-arithmetic could be put into one file rather than having so many files that all test the same lint... but it doesn't seem worth the effort. After https://github.com/rust-lang/rust/pull/119432 we might be able to remove most of them entirely as they will be covered by the new tests added there.
This commit is contained in:
commit
a95a363dba
2 changed files with 0 additions and 23 deletions
|
@ -1,9 +0,0 @@
|
|||
// build-fail
|
||||
// compile-flags: -C debug-assertions
|
||||
|
||||
#![deny(arithmetic_overflow)]
|
||||
|
||||
fn main() {
|
||||
let _n = 1i64 >> [64][0];
|
||||
//~^ ERROR: this arithmetic operation will overflow
|
||||
}
|
|
@ -1,14 +0,0 @@
|
|||
error: this arithmetic operation will overflow
|
||||
--> $DIR/overflowing-rsh-6.rs:7:14
|
||||
|
|
||||
LL | let _n = 1i64 >> [64][0];
|
||||
| ^^^^^^^^^^^^^^^ attempt to shift right by `64_i32`, which would overflow
|
||||
|
|
||||
note: the lint level is defined here
|
||||
--> $DIR/overflowing-rsh-6.rs:4:9
|
||||
|
|
||||
LL | #![deny(arithmetic_overflow)]
|
||||
| ^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
error: aborting due to 1 previous error
|
||||
|
Loading…
Reference in a new issue