File tree 6 files changed +14
-14
lines changed
6 files changed +14
-14
lines changed Original file line number Diff line number Diff line change @@ -316,7 +316,7 @@ impl<'a> Resolver<'a> {
316
316
// use foo::bar::self as abc -> foo::bar as abc
317
317
err. span_suggestion (
318
318
span,
319
- "Remove `::self`.. " ,
319
+ "consider importing the module directly " ,
320
320
"" . to_string ( ) ,
321
321
Applicability :: MachineApplicable ,
322
322
) ;
@@ -328,7 +328,7 @@ impl<'a> Resolver<'a> {
328
328
( span_with_rename. shrink_to_hi( ) , "}" . to_string( ) ) ,
329
329
] ;
330
330
err. multipart_suggestion (
331
- "..or add braces around `self`" ,
331
+ "alternatively, use the multi-path `use` syntax to import `self`" ,
332
332
braces,
333
333
Applicability :: MachineApplicable ,
334
334
) ;
Original file line number Diff line number Diff line change @@ -4,11 +4,11 @@ error[E0429]: `self` imports are only allowed within a { } list
4
4
LL | use std::fmt::self;
5
5
| ^^^^^^
6
6
|
7
- help: Remove `::self`..
7
+ help: consider importing the module directly
8
8
|
9
9
LL | use std::fmt;
10
10
| --
11
- help: ..or add braces around `self`
11
+ help: alternatively, use the multi-path `use` syntax to import `self`
12
12
|
13
13
LL | use std::fmt::{self};
14
14
| ^ ^
Original file line number Diff line number Diff line change @@ -10,11 +10,11 @@ error[E0429]: `self` imports are only allowed within a { } list
10
10
LL | use foo::self;
11
11
| ^^^^^^
12
12
|
13
- help: Remove `::self`..
13
+ help: consider importing the module directly
14
14
|
15
15
LL | use foo;
16
16
| --
17
- help: ..or add braces around `self`
17
+ help: alternatively, use the multi-path `use` syntax to import `self`
18
18
|
19
19
LL | use foo::{self};
20
20
| ^ ^
Original file line number Diff line number Diff line change @@ -4,11 +4,11 @@ error[E0429]: `self` imports are only allowed within a { } list
4
4
LL | use foo::self;
5
5
| ^^^^^^
6
6
|
7
- help: Remove `::self`..
7
+ help: consider importing the module directly
8
8
|
9
9
LL | use foo;
10
10
| --
11
- help: ..or add braces around `self`
11
+ help: alternatively, use the multi-path `use` syntax to import `self`
12
12
|
13
13
LL | use foo::{self};
14
14
| ^ ^
@@ -19,11 +19,11 @@ error[E0429]: `self` imports are only allowed within a { } list
19
19
LL | use std::mem::self;
20
20
| ^^^^^^
21
21
|
22
- help: Remove `::self`..
22
+ help: consider importing the module directly
23
23
|
24
24
LL | use std::mem;
25
25
| --
26
- help: ..or add braces around `self`
26
+ help: alternatively, use the multi-path `use` syntax to import `self`
27
27
|
28
28
LL | use std::mem::{self};
29
29
| ^ ^
Original file line number Diff line number Diff line change @@ -4,11 +4,11 @@ error[E0429]: `self` imports are only allowed within a { } list
4
4
LL | use foo::bar::self;
5
5
| ^^^^^^
6
6
|
7
- help: Remove `::self`..
7
+ help: consider importing the module directly
8
8
|
9
9
LL | use foo::bar;
10
10
| --
11
- help: ..or add braces around `self`
11
+ help: alternatively, use the multi-path `use` syntax to import `self`
12
12
|
13
13
LL | use foo::bar::{self};
14
14
| ^ ^
Original file line number Diff line number Diff line change @@ -4,11 +4,11 @@ error[E0429]: `self` imports are only allowed within a { } list
4
4
LL | use foo::bar::self as abc;
5
5
| ^^^^^^
6
6
|
7
- help: Remove `::self`..
7
+ help: consider importing the module directly
8
8
|
9
9
LL | use foo::bar as abc;
10
10
| --
11
- help: ..or add braces around `self`
11
+ help: alternatively, use the multi-path `use` syntax to import `self`
12
12
|
13
13
LL | use foo::bar::{self as abc};
14
14
| ^ ^
You can’t perform that action at this time.
0 commit comments