Closed as not planned
Description
For example, while working on PR #337 I triggered the clippy lint #[warn(clippy::std-instead-of-alloc)]
CI error log
error: used import from `std` instead of `alloc`
--> src/lib.rs:2423:8
|
2423 | T: std::string::ToString + FromStr + PartialEq + fmt::Debug,
| ^^^^^^^^^^^^^^^^^^^^^
|
= help: consider importing the item from `alloc`
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#std_instead_of_alloc
= note: `-D clippy::std-instead-of-alloc` implied by `-D warnings`
error: used import from `std` instead of `core`
--> src/tests.rs:37:14
|
37 | ) -> std::result::Result<Self::Ok, Self::Err> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: consider importing the item from `core`
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#std_instead_of_core
= note: `-D clippy::std-instead-of-core` implied by `-D warnings`
error: used import from `std` instead of `alloc`
--> src/tests.rs:69:26
|
69 | struct TestError<E = std::string::ParseError>(&'static str, Option<E>);
| ^^^^^^^^^^^^^^^^^^^^^^^
|
= help: consider importing the item from `alloc`
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#std_instead_of_alloc
error: used import from `std` instead of `core`
--> src/tests.rs:115:18
|
115 | ) -> std::result::Result<Self::Ok, Self::Err> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: consider importing the item from `core`
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#std_instead_of_core
Ideally this would have triggered a github actions "warnings::"
annotation instead of a hard failure.
This would still flag the issue without completely failing the build.
Metadata
Metadata
Assignees
Labels
No labels