Skip to content

Commit a84f508

Browse files
committed
adjust incremental tests
1 parent f076f17 commit a84f508

File tree

11 files changed

+29
-28
lines changed

11 files changed

+29
-28
lines changed

tests/incremental/callee_caller_cross_crate/b.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
extern crate a;
88

9-
#[rustc_clean(except="typeck", cfg="rpass2")]
9+
#[rustc_clean(except="typeck,optimized_mir", cfg="rpass2")]
1010
pub fn call_function0() {
1111
a::function0(77);
1212
}

tests/incremental/dirty_clean.rs

+1
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ mod y {
3636
//[cfail2]~| ERROR `type_of(y)` should be dirty but is not
3737
//[cfail2]~| ERROR `fn_sig(y)` should be dirty but is not
3838
//[cfail2]~| ERROR `typeck(y)` should be clean but is not
39+
//[cfail2]~| ERROR `optimized_mir(y)` should be clean but is not
3940
x::x();
4041
}
4142
}

tests/incremental/hashes/call_expressions.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -62,9 +62,9 @@ mod change_callee_indirectly_function {
6262
#[cfg(not(any(cfail1,cfail4)))]
6363
use super::callee2 as callee;
6464

65-
#[rustc_clean(except="opt_hir_owner_nodes,typeck", cfg="cfail2")]
65+
#[rustc_clean(except="opt_hir_owner_nodes,typeck,optimized_mir", cfg="cfail2")]
6666
#[rustc_clean(cfg="cfail3")]
67-
#[rustc_clean(except="opt_hir_owner_nodes,typeck", cfg="cfail5")]
67+
#[rustc_clean(except="opt_hir_owner_nodes,typeck,optimized_mir", cfg="cfail5")]
6868
#[rustc_clean(cfg="cfail6")]
6969
pub fn change_callee_indirectly_function() {
7070
callee(1, 2)

tests/incremental/hashes/indexing_expressions.rs

+14-14
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ fn change_simple_index(slice: &[u32]) -> u32 {
2323
}
2424

2525
#[cfg(not(any(cfail1,cfail4)))]
26-
#[rustc_clean(except="opt_hir_owner_nodes", cfg="cfail2")]
26+
#[rustc_clean(except="opt_hir_owner_nodes,optimized_mir", cfg="cfail2")]
2727
#[rustc_clean(cfg="cfail3")]
28-
#[rustc_clean(except="opt_hir_owner_nodes", cfg="cfail5")]
28+
#[rustc_clean(except="opt_hir_owner_nodes,optimized_mir", cfg="cfail5")]
2929
#[rustc_clean(cfg="cfail6")]
3030
fn change_simple_index(slice: &[u32]) -> u32 {
3131
slice[4]
@@ -40,9 +40,9 @@ fn change_lower_bound(slice: &[u32]) -> &[u32] {
4040
}
4141

4242
#[cfg(not(any(cfail1,cfail4)))]
43-
#[rustc_clean(except="opt_hir_owner_nodes", cfg="cfail2")]
43+
#[rustc_clean(except="opt_hir_owner_nodes,optimized_mir", cfg="cfail2")]
4444
#[rustc_clean(cfg="cfail3")]
45-
#[rustc_clean(except="opt_hir_owner_nodes", cfg="cfail5")]
45+
#[rustc_clean(except="opt_hir_owner_nodes,optimized_mir", cfg="cfail5")]
4646
#[rustc_clean(cfg="cfail6")]
4747
fn change_lower_bound(slice: &[u32]) -> &[u32] {
4848
&slice[2..5]
@@ -57,9 +57,9 @@ fn change_upper_bound(slice: &[u32]) -> &[u32] {
5757
}
5858

5959
#[cfg(not(any(cfail1,cfail4)))]
60-
#[rustc_clean(except="opt_hir_owner_nodes", cfg="cfail2")]
60+
#[rustc_clean(except="opt_hir_owner_nodes,optimized_mir", cfg="cfail2")]
6161
#[rustc_clean(cfg="cfail3")]
62-
#[rustc_clean(except="opt_hir_owner_nodes", cfg="cfail5")]
62+
#[rustc_clean(except="opt_hir_owner_nodes,optimized_mir", cfg="cfail5")]
6363
#[rustc_clean(cfg="cfail6")]
6464
fn change_upper_bound(slice: &[u32]) -> &[u32] {
6565
&slice[3..7]
@@ -74,9 +74,9 @@ fn add_lower_bound(slice: &[u32]) -> &[u32] {
7474
}
7575

7676
#[cfg(not(any(cfail1,cfail4)))]
77-
#[rustc_clean(except="opt_hir_owner_nodes,typeck", cfg="cfail2")]
77+
#[rustc_clean(except="opt_hir_owner_nodes,typeck,optimized_mir", cfg="cfail2")]
7878
#[rustc_clean(cfg="cfail3")]
79-
#[rustc_clean(except="opt_hir_owner_nodes,typeck", cfg="cfail5")]
79+
#[rustc_clean(except="opt_hir_owner_nodes,typeck,optimized_mir", cfg="cfail5")]
8080
#[rustc_clean(cfg="cfail6")]
8181
fn add_lower_bound(slice: &[u32]) -> &[u32] {
8282
&slice[3..4]
@@ -91,9 +91,9 @@ fn add_upper_bound(slice: &[u32]) -> &[u32] {
9191
}
9292

9393
#[cfg(not(any(cfail1,cfail4)))]
94-
#[rustc_clean(except="opt_hir_owner_nodes,typeck", cfg="cfail2")]
94+
#[rustc_clean(except="opt_hir_owner_nodes,typeck,optimized_mir", cfg="cfail2")]
9595
#[rustc_clean(cfg="cfail3")]
96-
#[rustc_clean(except="opt_hir_owner_nodes,typeck", cfg="cfail5")]
96+
#[rustc_clean(except="opt_hir_owner_nodes,typeck,optimized_mir", cfg="cfail5")]
9797
#[rustc_clean(cfg="cfail6")]
9898
fn add_upper_bound(slice: &[u32]) -> &[u32] {
9999
&slice[3..7]
@@ -108,9 +108,9 @@ fn change_mutability(slice: &mut [u32]) -> u32 {
108108
}
109109

110110
#[cfg(not(any(cfail1,cfail4)))]
111-
#[rustc_clean(except="opt_hir_owner_nodes,typeck", cfg="cfail2")]
111+
#[rustc_clean(except="opt_hir_owner_nodes,typeck,optimized_mir", cfg="cfail2")]
112112
#[rustc_clean(cfg="cfail3")]
113-
#[rustc_clean(except="opt_hir_owner_nodes,typeck", cfg="cfail5")]
113+
#[rustc_clean(except="opt_hir_owner_nodes,typeck,optimized_mir", cfg="cfail5")]
114114
#[rustc_clean(cfg="cfail6")]
115115
fn change_mutability(slice: &mut [u32]) -> u32 {
116116
(& slice[3..5])[0]
@@ -125,9 +125,9 @@ fn exclusive_to_inclusive_range(slice: &[u32]) -> &[u32] {
125125
}
126126

127127
#[cfg(not(any(cfail1,cfail4)))]
128-
#[rustc_clean(except="opt_hir_owner_nodes,typeck", cfg="cfail2")]
128+
#[rustc_clean(except="opt_hir_owner_nodes,typeck,optimized_mir", cfg="cfail2")]
129129
#[rustc_clean(cfg="cfail3")]
130-
#[rustc_clean(except="opt_hir_owner_nodes,typeck", cfg="cfail5")]
130+
#[rustc_clean(except="opt_hir_owner_nodes,typeck,optimized_mir", cfg="cfail5")]
131131
#[rustc_clean(cfg="cfail6")]
132132
fn exclusive_to_inclusive_range(slice: &[u32]) -> &[u32] {
133133
&slice[3..=7]

tests/incremental/ich_method_call_trait_scope.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ mod mod3 {
2626
#[cfg(rpass2)]
2727
use Trait2;
2828

29-
#[rustc_clean(except="typeck", cfg="rpass2")]
29+
#[rustc_clean(except="typeck,optimized_mir", cfg="rpass2")]
3030
fn bar() {
3131
().method();
3232
}

tests/incremental/ich_resolve_results.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ mod mod3 {
3636
}
3737

3838
#[rustc_clean(cfg="rpass2")]
39-
#[rustc_clean(except="opt_hir_owner_nodes,typeck", cfg="rpass3")]
39+
#[rustc_clean(except="opt_hir_owner_nodes,typeck,optimized_mir", cfg="rpass3")]
4040
fn in_type() {
4141
test::<Foo>();
4242
}

tests/incremental/struct_add_field.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,12 @@ pub struct Y {
2121
pub y: char
2222
}
2323

24-
#[rustc_clean(except="fn_sig,typeck", cfg="rpass2")]
24+
#[rustc_clean(except="fn_sig,typeck,optimized_mir", cfg="rpass2")]
2525
pub fn use_X(x: X) -> u32 {
2626
x.x as u32
2727
}
2828

29-
#[rustc_clean(except="typeck", cfg="rpass2")]
29+
#[rustc_clean(except="typeck,optimized_mir", cfg="rpass2")]
3030
pub fn use_EmbedX(embed: EmbedX) -> u32 {
3131
embed.x.x as u32
3232
}

tests/incremental/struct_change_field_type.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,13 @@ pub struct Y {
2424
pub y: char
2525
}
2626

27-
#[rustc_clean(except="typeck", cfg="rpass2")]
27+
#[rustc_clean(except="typeck,optimized_mir", cfg="rpass2")]
2828
pub fn use_X() -> u32 {
2929
let x: X = X { x: 22 };
3030
x.x as u32
3131
}
3232

33-
#[rustc_clean(except="typeck", cfg="rpass2")]
33+
#[rustc_clean(except="typeck,optimized_mir", cfg="rpass2")]
3434
pub fn use_EmbedX(x: EmbedX) -> u32 {
3535
let x: X = X { x: 22 };
3636
x.x as u32

tests/incremental/struct_change_field_type_cross_crate/b.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@ extern crate a;
88

99
use a::*;
1010

11-
#[rustc_clean(except="typeck", cfg="rpass2")]
11+
#[rustc_clean(except="typeck,optimized_mir", cfg="rpass2")]
1212
pub fn use_X() -> u32 {
1313
let x: X = X { x: 22 };
1414
x.x as u32
1515
}
1616

17-
#[rustc_clean(except="typeck", cfg="rpass2")]
17+
#[rustc_clean(except="typeck,optimized_mir", cfg="rpass2")]
1818
pub fn use_EmbedX(embed: EmbedX) -> u32 {
1919
embed.x.x as u32
2020
}

tests/incremental/struct_remove_field.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,12 @@ pub struct Y {
2525
pub y: char
2626
}
2727

28-
#[rustc_clean(except="typeck,fn_sig", cfg="rpass2")]
28+
#[rustc_clean(except="typeck,fn_sig,optimized_mir", cfg="rpass2")]
2929
pub fn use_X(x: X) -> u32 {
3030
x.x as u32
3131
}
3232

33-
#[rustc_clean(except="typeck", cfg="rpass2")]
33+
#[rustc_clean(except="typeck,optimized_mir", cfg="rpass2")]
3434
pub fn use_EmbedX(embed: EmbedX) -> u32 {
3535
embed.x.x as u32
3636
}

tests/incremental/type_alias_cross_crate/b.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
extern crate a;
88

9-
#[rustc_clean(except="typeck", cfg="rpass2")]
9+
#[rustc_clean(except="typeck,optimized_mir", cfg="rpass2")]
1010
#[rustc_clean(cfg="rpass3")]
1111
pub fn use_X() -> u32 {
1212
let x: a::X = 22;

0 commit comments

Comments
 (0)