Skip to content

Commit 8eef102

Browse files
committed
update tests for migrate mode by default
1 parent aa6fb6c commit 8eef102

File tree

1,356 files changed

+5881
-21887
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,356 files changed

+5881
-21887
lines changed

src/test/incremental/feature_gate.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44
// compile-flags: -Z query-dep-graph
55

66
#![feature(rustc_attrs)]
7-
#![cfg_attr(rpass1, feature(nll))]
7+
#![cfg_attr(rpass1, feature(abi_unadjusted))]
88

99
fn main() {
10-
let mut v = vec![1];
11-
v.push(v[0]);
12-
//[cfail2]~^ ERROR cannot borrow
1310
}
11+
12+
extern "unadjusted" fn foo() {}
13+
//[cfail2]~^ ERROR: unadjusted ABI is an implementation detail and perma-unstable

src/test/mir-opt/match_test.rs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -60,9 +60,11 @@ fn main() {
6060
// goto -> bb16;
6161
// }
6262
// bb12: {
63-
// StorageLive(_8);
64-
// _8 = _2;
65-
// switchInt(move _8) -> [false: bb6, otherwise: bb11];
63+
// _8 = &shallow _1;
64+
// StorageLive(_9);
65+
// _9 = _2;
66+
// FakeRead(ForMatchGuard, _8);
67+
// switchInt(move _9) -> [false: bb6, otherwise: bb11];
6668
// }
6769
// bb13: {
6870
// _3 = const 1i32;
@@ -77,7 +79,7 @@ fn main() {
7779
// goto -> bb16;
7880
// }
7981
// bb16: {
80-
// StorageDead(_8);
82+
// StorageDead(_9);
8183
// _0 = ();
8284
// StorageDead(_2);
8385
// StorageDead(_1);

src/test/run-fail/borrowck-local-borrow.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// error-pattern:panic 1
22

3-
// revisions: ast mir
3+
// revisions: migrate mir
44
//[mir]compile-flags: -Z borrowck=mir
55

66
fn main() {

src/test/run-pass/asm-in-moved.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
// revisions: ast mir
2-
//[mir]compile-flags: -Z borrowck=mir
3-
41
#![feature(asm)]
52
#![allow(dead_code)]
63

src/test/run-pass/asm-out-assign.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
// revisions ast mir
2-
//[mir]compile-flags: -Z borrowck=mir
3-
41
#![feature(asm)]
52

63
#[cfg(any(target_arch = "x86", target_arch = "x86_64"))]

src/test/run-pass/borrowck/borrowck-assignment-to-static-mut.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,6 @@
22
#![allow(dead_code)]
33
// Test taken from #45641 (https://github.com/rust-lang/rust/issues/45641)
44

5-
// revisions: ast mir
6-
//[mir]compile-flags: -Z borrowck=mir
7-
85
static mut Y: u32 = 0;
96

107
unsafe fn should_ok() {

src/test/run-pass/borrowck/borrowck-unsafe-static-mutable-borrows.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
// run-pass
2-
// revisions: ast mir
3-
//[mir]compile-flags: -Z borrowck=mir
42

53
// Test file taken from issue 45129 (https://github.com/rust-lang/rust/issues/45129)
64

src/test/run-pass/borrowck/two-phase-baseline.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
// run-pass
2-
// compile-flags: -Z borrowck=mir -Z two-phase-borrows
32

43
// This is the "goto example" for why we want two phase borrows.
54

src/test/run-pass/borrowck/two-phase-control-flow-split-before-activation.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,4 @@
11
// run-pass
2-
// revisions: lxl nll
3-
//[lxl]compile-flags: -Z borrowck=mir -Z two-phase-borrows
4-
5-
#![cfg_attr(nll, feature(nll))]
62

73
fn main() {
84
let mut a = 0;

src/test/run-pass/drop/dynamic-drop.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
// run-pass
22
#![allow(unused_assignments)]
33
#![allow(unused_variables)]
4-
// revisions:lexical nll
5-
#![cfg_attr(nll, feature(nll))]
64

75
// ignore-wasm32-bare compiled with panic=abort by default
86

0 commit comments

Comments
 (0)