Skip to content

Commit 7e19168

Browse files
committed
Fix fallout in tests.
1 parent d54a6d9 commit 7e19168

6 files changed

+38
-44
lines changed

src/test/ui/span/import-ty-params.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@ macro_rules! import {
2121
}
2222

2323
fn f1() {
24-
import! { a::b::c::S<u8> } //~ ERROR generic arguments in import path
24+
import! { a::b::c::S<u8> } //~ ERROR unexpected generic arguments in path
2525
}
2626
fn f2() {
27-
import! { a::b::c::S<> } //~ ERROR generic arguments in import path
27+
import! { a::b::c::S<> } //~ ERROR unexpected generic arguments in path
2828
}
2929

3030
fn main() {}
+8-8
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
1-
error: generic arguments in import path
2-
--> $DIR/import-ty-params.rs:24:25
1+
error: unexpected generic arguments in path
2+
--> $DIR/import-ty-params.rs:24:15
33
|
4-
24 | import! { a::b::c::S<u8> } //~ ERROR generic arguments in import path
5-
| ^^^^
4+
24 | import! { a::b::c::S<u8> } //~ ERROR unexpected generic arguments in path
5+
| ^^^^^^^^^^^^^^
66

7-
error: generic arguments in import path
8-
--> $DIR/import-ty-params.rs:27:25
7+
error: unexpected generic arguments in path
8+
--> $DIR/import-ty-params.rs:27:15
99
|
10-
27 | import! { a::b::c::S<> } //~ ERROR generic arguments in import path
11-
| ^^
10+
27 | import! { a::b::c::S<> } //~ ERROR unexpected generic arguments in path
11+
| ^^^^^^^^^^^^
1212

1313
error: aborting due to 2 previous errors
1414

src/test/ui/span/macro-ty-params.rs

-10
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,6 @@ macro_rules! m {
1616

1717
fn main() {
1818
foo::<T>!();
19-
//~^ ERROR generic arguments in macro path
20-
//~| ERROR generic arguments in macro path
21-
//~| ERROR generic arguments in macro path
2219
foo::<>!();
23-
//~^ ERROR generic arguments in macro path
24-
//~| ERROR generic arguments in macro path
25-
//~| ERROR generic arguments in macro path
2620
m!(MyTrait<>);
27-
//~^ ERROR generic arguments in macro path
28-
//~| ERROR generic arguments in macro path
29-
//~| ERROR generic arguments in macro path
30-
//~| ERROR generic arguments in macro path
3121
}
+17-5
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,32 @@
1+
error: unexpected generic arguments in path
2+
--> $DIR/macro-ty-params.rs:20:8
3+
|
4+
20 | m!(MyTrait<>);
5+
| ^^^^^^^^^
6+
7+
error: unexpected generic arguments in path
8+
--> $DIR/macro-ty-params.rs:20:8
9+
|
10+
20 | m!(MyTrait<>);
11+
| ^^^^^^^^^
12+
113
error: generic arguments in macro path
214
--> $DIR/macro-ty-params.rs:18:8
315
|
416
18 | foo::<T>!();
517
| ^^^^^
618

719
error: generic arguments in macro path
8-
--> $DIR/macro-ty-params.rs:22:8
20+
--> $DIR/macro-ty-params.rs:19:8
921
|
10-
22 | foo::<>!();
22+
19 | foo::<>!();
1123
| ^^^^
1224

1325
error: generic arguments in macro path
14-
--> $DIR/macro-ty-params.rs:26:15
26+
--> $DIR/macro-ty-params.rs:20:15
1527
|
16-
26 | m!(MyTrait<>);
28+
20 | m!(MyTrait<>);
1729
| ^^
1830

19-
error: aborting due to 3 previous errors
31+
error: aborting due to 5 previous errors
2032

src/test/ui/span/visibility-ty-params.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,11 @@ macro_rules! m {
1313
}
1414

1515
struct S<T>(T);
16-
m!{ S<u8> } //~ ERROR generic arguments in visibility path
16+
m!{ S<u8> } //~ ERROR unexpected generic arguments in path
1717
//~^ ERROR expected module, found struct `S`
1818

1919
mod m {
20-
m!{ m<> } //~ ERROR generic arguments in visibility path
20+
m!{ m<> } //~ ERROR unexpected generic arguments in path
2121
}
2222

2323
fn main() {}
+9-17
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,14 @@
1-
error: generic arguments in visibility path
2-
--> $DIR/visibility-ty-params.rs:16:6
3-
|
4-
16 | m!{ S<u8> } //~ ERROR generic arguments in visibility path
5-
| ^^^^
6-
7-
error: generic arguments in visibility path
8-
--> $DIR/visibility-ty-params.rs:20:10
1+
error: unexpected generic arguments in path
2+
--> $DIR/visibility-ty-params.rs:16:5
93
|
10-
20 | m!{ m<> } //~ ERROR generic arguments in visibility path
11-
| ^^
4+
16 | m!{ S<u8> } //~ ERROR unexpected generic arguments in path
5+
| ^^^^^
126

13-
error[E0577]: expected module, found struct `S`
14-
--> $DIR/visibility-ty-params.rs:16:5
7+
error: unexpected generic arguments in path
8+
--> $DIR/visibility-ty-params.rs:20:9
159
|
16-
16 | m!{ S<u8> } //~ ERROR generic arguments in visibility path
17-
| -^^^^
18-
| |
19-
| did you mean `m`?
10+
20 | m!{ m<> } //~ ERROR unexpected generic arguments in path
11+
| ^^^
2012

21-
error: aborting due to 3 previous errors
13+
error: aborting due to 2 previous errors
2214

0 commit comments

Comments
 (0)