Skip to content

Commit 7148d37

Browse files
committed
bless tests
1 parent de8648f commit 7148d37

16 files changed

+18
-143
lines changed

tests/ui/imports/ambiguous-1.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ macro_rules! m {
99

1010
mod openssl {
1111
pub use self::evp::*;
12-
//~^ WARNING ambiguous glob re-exports
1312
pub use self::handwritten::*;
1413

1514
mod evp {

tests/ui/imports/ambiguous-1.stderr

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,5 @@
1-
warning: ambiguous glob re-exports
2-
--> $DIR/ambiguous-1.rs:11:13
3-
|
4-
LL | pub use self::evp::*;
5-
| ^^^^^^^^^^^^ the name `id` in the value namespace is first re-exported here
6-
LL |
7-
LL | pub use self::handwritten::*;
8-
| -------------------- but the name `id` in the value namespace is also re-exported here
9-
|
10-
= note: `#[warn(ambiguous_glob_reexports)]` on by default
11-
121
warning: `id` is ambiguous
13-
--> $DIR/ambiguous-1.rs:27:5
2+
--> $DIR/ambiguous-1.rs:26:5
143
|
154
LL | id();
165
| ^^ ambiguous name
@@ -25,12 +14,12 @@ LL | pub use self::evp::*;
2514
| ^^^^^^^^^^^^
2615
= help: consider adding an explicit import of `id` to disambiguate
2716
note: `id` could also refer to the function imported here
28-
--> $DIR/ambiguous-1.rs:13:13
17+
--> $DIR/ambiguous-1.rs:12:13
2918
|
3019
LL | pub use self::handwritten::*;
3120
| ^^^^^^^^^^^^^^^^^^^^
3221
= help: consider adding an explicit import of `id` to disambiguate
3322
= note: `#[warn(ambiguous_glob_imports)]` on by default
3423

35-
warning: 2 warnings emitted
24+
warning: 1 warning emitted
3625

tests/ui/imports/ambiguous-17.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
//@ check-pass
22
// https://github.com/rust-lang/rust/pull/113099#issuecomment-1638206152
33

4-
pub use evp::*; //~ WARNING ambiguous glob re-exports
4+
pub use evp::*;
55
pub use handwritten::*;
66

77
macro_rules! m {

tests/ui/imports/ambiguous-17.stderr

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,3 @@
1-
warning: ambiguous glob re-exports
2-
--> $DIR/ambiguous-17.rs:4:9
3-
|
4-
LL | pub use evp::*;
5-
| ^^^^^^ the name `id` in the value namespace is first re-exported here
6-
LL | pub use handwritten::*;
7-
| -------------- but the name `id` in the value namespace is also re-exported here
8-
|
9-
= note: `#[warn(ambiguous_glob_reexports)]` on by default
10-
111
warning: `id` is ambiguous
122
--> $DIR/ambiguous-17.rs:26:5
133
|
@@ -31,5 +21,5 @@ LL | pub use handwritten::*;
3121
= help: consider adding an explicit import of `id` to disambiguate
3222
= note: `#[warn(ambiguous_glob_imports)]` on by default
3323

34-
warning: 2 warnings emitted
24+
warning: 1 warning emitted
3525

tests/ui/imports/ambiguous-4-extern.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ macro_rules! m {
77
};
88
}
99

10-
pub use evp::*; //~ WARNING ambiguous glob re-exports
10+
pub use evp::*;
1111
pub use handwritten::*;
1212

1313
mod evp {

tests/ui/imports/ambiguous-4-extern.stderr

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,3 @@
1-
warning: ambiguous glob re-exports
2-
--> $DIR/ambiguous-4-extern.rs:10:9
3-
|
4-
LL | pub use evp::*;
5-
| ^^^^^^ the name `id` in the value namespace is first re-exported here
6-
LL | pub use handwritten::*;
7-
| -------------- but the name `id` in the value namespace is also re-exported here
8-
|
9-
= note: `#[warn(ambiguous_glob_reexports)]` on by default
10-
111
warning: `id` is ambiguous
122
--> $DIR/ambiguous-4-extern.rs:23:5
133
|
@@ -31,5 +21,5 @@ LL | pub use handwritten::*;
3121
= help: consider adding an explicit import of `id` to disambiguate
3222
= note: `#[warn(ambiguous_glob_imports)]` on by default
3323

34-
warning: 2 warnings emitted
24+
warning: 1 warning emitted
3525

tests/ui/imports/ambiguous-9.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@ pub mod dsl {
55
mod range {
66
pub fn date_range() {}
77
}
8-
pub use self::range::*; //~ WARNING ambiguous glob re-exports
8+
pub use self::range::*;
99
use super::prelude::*;
1010
}
1111

1212
pub mod prelude {
1313
mod t {
1414
pub fn date_range() {}
1515
}
16-
pub use self::t::*; //~ WARNING ambiguous glob re-exports
16+
pub use self::t::*;
1717
pub use super::dsl::*;
1818
}
1919

tests/ui/imports/ambiguous-9.stderr

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,3 @@
1-
warning: ambiguous glob re-exports
2-
--> $DIR/ambiguous-9.rs:8:13
3-
|
4-
LL | pub use self::range::*;
5-
| ^^^^^^^^^^^^^^ the name `date_range` in the value namespace is first re-exported here
6-
LL | use super::prelude::*;
7-
| ----------------- but the name `date_range` in the value namespace is also re-exported here
8-
|
9-
= note: `#[warn(ambiguous_glob_reexports)]` on by default
10-
111
warning: `date_range` is ambiguous
122
--> $DIR/ambiguous-9.rs:24:5
133
|
@@ -31,14 +21,6 @@ LL | use super::prelude::*;
3121
= help: consider adding an explicit import of `date_range` to disambiguate
3222
= note: `#[warn(ambiguous_glob_imports)]` on by default
3323

34-
warning: ambiguous glob re-exports
35-
--> $DIR/ambiguous-9.rs:16:13
36-
|
37-
LL | pub use self::t::*;
38-
| ^^^^^^^^^^ the name `date_range` in the value namespace is first re-exported here
39-
LL | pub use super::dsl::*;
40-
| ------------- but the name `date_range` in the value namespace is also re-exported here
41-
4224
warning: `date_range` is ambiguous
4325
--> $DIR/ambiguous-9.rs:24:5
4426
|
@@ -61,5 +43,5 @@ LL | use prelude::*;
6143
| ^^^^^^^^^^
6244
= help: consider adding an explicit import of `date_range` to disambiguate
6345

64-
warning: 4 warnings emitted
46+
warning: 2 warnings emitted
6547

tests/ui/imports/issue-56125.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ mod m2 {
1515
mod m3 {
1616
mod empty {}
1717
use empty::issue_56125; //~ ERROR unresolved import `empty::issue_56125`
18-
use issue_56125::*; //~ ERROR `issue_56125` is ambiguous
18+
use issue_56125::*;
1919
}
2020

2121
fn main() {}

tests/ui/imports/issue-56125.stderr

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -54,24 +54,7 @@ LL | use issue_56125::non_last_segment::non_last_segment::*;
5454
= help: consider adding an explicit import of `issue_56125` to disambiguate
5555
= help: or use `self::issue_56125` to refer to this module unambiguously
5656

57-
error[E0659]: `issue_56125` is ambiguous
58-
--> $DIR/issue-56125.rs:18:9
59-
|
60-
LL | use issue_56125::*;
61-
| ^^^^^^^^^^^ ambiguous name
62-
|
63-
= note: ambiguous because of a conflict between a name from a glob import and an outer scope during import or macro resolution
64-
= note: `issue_56125` could refer to a crate passed with `--extern`
65-
= help: use `::issue_56125` to refer to this crate unambiguously
66-
note: `issue_56125` could also refer to the module imported here
67-
--> $DIR/issue-56125.rs:18:9
68-
|
69-
LL | use issue_56125::*;
70-
| ^^^^^^^^^^^^^^
71-
= help: consider adding an explicit import of `issue_56125` to disambiguate
72-
= help: or use `self::issue_56125` to refer to this module unambiguously
73-
74-
error: aborting due to 4 previous errors
57+
error: aborting due to 3 previous errors
7558

7659
Some errors have detailed explanations: E0432, E0659.
7760
For more information about an error, try `rustc --explain E0432`.

0 commit comments

Comments
 (0)