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
33 |
44LL | use std::fmt::{};
5- | ^^^^^^^^^^^^^^^^^
5+ | ---- ^^^^^^^^^^^^- help: remove the whole `use` item
66 |
77note: lint level defined here
88 --> $DIR/lint-unused-imports.rs:1:9
@@ -14,37 +14,39 @@ error: unused imports: `None`, `Some`
1414 --> $DIR/lint-unused-imports.rs:12:27
1515 |
1616LL | use std::option::Option::{Some, None};
17- | ^^^^ ^^^^
17+ | -------------------------- ^^^^-- ^^^^-- help: remove the whole `use` item
1818
1919error: unused import: `test::A`
2020 --> $DIR/lint-unused-imports.rs:15:5
2121 |
2222LL | use test::A; //~ ERROR unused import: `test::A`
23- | ^^^^^^^
23+ | ---- ^^^^^^^- help: remove the whole `use` item
2424
2525error: unused import: `bar`
2626 --> $DIR/lint-unused-imports.rs:24:18
2727 |
2828LL | use test2::{foo, bar}; //~ ERROR unused import: `bar`
29- | ^^^
29+ | --^^^
30+ | |
31+ | help: remove the unused import
3032
3133error: unused import: `foo::Square`
3234 --> $DIR/lint-unused-imports.rs:52:13
3335 |
3436LL | use foo::Square; //~ ERROR unused import: `foo::Square`
35- | ^^^^^^^^^^^
37+ | ---- ^^^^^^^^^^^- help: remove the whole `use` item
3638
3739error: unused import: `self::g`
3840 --> $DIR/lint-unused-imports.rs:68:9
3941 |
4042LL | use self::g; //~ ERROR unused import: `self::g`
41- | ^^^^^^^
43+ | ---- ^^^^^^^- help: remove the whole `use` item
4244
4345error: unused import: `test2::foo`
4446 --> $DIR/lint-unused-imports.rs:77:9
4547 |
4648LL | use test2::foo; //~ ERROR unused import: `test2::foo`
47- | ^^^^^^^^^^
49+ | ---- ^^^^^^^^^^- help: remove the whole `use` item
4850
4951error: unused import: `test::B2`
5052 --> $DIR/lint-unused-imports.rs:20:5
0 commit comments