1
- error: unused import: `use std::fmt::{}; `
2
- --> $DIR/lint-unused-imports.rs:8:1
1
+ error: unused import: `std::fmt::{}`
2
+ --> $DIR/lint-unused-imports.rs:8:5
3
3
|
4
4
LL | use std::fmt::{};
5
- | ^^^^^^^^^^^^^^^^^
5
+ | ---- ^^^^^^^^^^^^- help: remove the whole `use` item
6
6
|
7
7
note: lint level defined here
8
8
--> $DIR/lint-unused-imports.rs:1:9
@@ -14,37 +14,39 @@ error: unused imports: `None`, `Some`
14
14
--> $DIR/lint-unused-imports.rs:12:27
15
15
|
16
16
LL | use std::option::Option::{Some, None};
17
- | ^^^^ ^^^^
17
+ | -------------------------- ^^^^-- ^^^^-- help: remove the whole `use` item
18
18
19
19
error: unused import: `test::A`
20
20
--> $DIR/lint-unused-imports.rs:15:5
21
21
|
22
22
LL | use test::A; //~ ERROR unused import: `test::A`
23
- | ^^^^^^^
23
+ | ---- ^^^^^^^- help: remove the whole `use` item
24
24
25
25
error: unused import: `bar`
26
26
--> $DIR/lint-unused-imports.rs:24:18
27
27
|
28
28
LL | use test2::{foo, bar}; //~ ERROR unused import: `bar`
29
- | ^^^
29
+ | --^^^
30
+ | |
31
+ | help: remove the unused import
30
32
31
33
error: unused import: `foo::Square`
32
34
--> $DIR/lint-unused-imports.rs:52:13
33
35
|
34
36
LL | use foo::Square; //~ ERROR unused import: `foo::Square`
35
- | ^^^^^^^^^^^
37
+ | ---- ^^^^^^^^^^^- help: remove the whole `use` item
36
38
37
39
error: unused import: `self::g`
38
40
--> $DIR/lint-unused-imports.rs:68:9
39
41
|
40
42
LL | use self::g; //~ ERROR unused import: `self::g`
41
- | ^^^^^^^
43
+ | ---- ^^^^^^^- help: remove the whole `use` item
42
44
43
45
error: unused import: `test2::foo`
44
46
--> $DIR/lint-unused-imports.rs:77:9
45
47
|
46
48
LL | use test2::foo; //~ ERROR unused import: `test2::foo`
47
- | ^^^^^^^^^^
49
+ | ---- ^^^^^^^^^^- help: remove the whole `use` item
48
50
49
51
error: unused import: `test::B2`
50
52
--> $DIR/lint-unused-imports.rs:20:5
0 commit comments