GitHub Actions / clippy
failed
Apr 6, 2024 in 0s
clippy
3 errors
Details
Results
Message level | Amount |
---|---|
Internal compiler error | 0 |
Error | 3 |
Warning | 0 |
Note | 0 |
Help | 0 |
Versions
- rustc 1.79.0-nightly (9d79cd5f7 2024-04-05)
- cargo 1.79.0-nightly (0637083df 2024-04-02)
- clippy 0.1.79 (9d79cd5 2024-04-05)
Annotations
Check failure on line 46 in src/protocol.rs
github-actions / clippy
non-local `impl` definition, they should be avoided as they go against expectation
error: non-local `impl` definition, they should be avoided as they go against expectation
--> src/protocol.rs:46:45
|
46 | #[derive(Clone, Copy, Debug, FromPrimitive, ToPrimitive)]
| ^^^^^^^^^^^
|
= help: move this `impl` block outside the of the current constant `_IMPL_NUM_ToPrimitive_FOR_RequestType`
= note: an `impl` definition is non-local if it is nested inside an item and may impact type checking outside of that item. This can be the case if neither the trait or the self type are at the same nesting level as the `impl`
= note: one exception to the rule are anon-const (`const _: () = { ... }`) at top-level module and anon-const at the same nesting as the trait or type
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
= note: the derive macro `ToPrimitive` may come from an old version of the `num_derive` crate, try updating your dependency with `cargo update -p num_derive`
= note: this error originates in the derive macro `ToPrimitive` (in Nightly builds, run with -Z macro-backtrace for more info)
Check failure on line 46 in src/protocol.rs
github-actions / clippy
non-local `impl` definition, they should be avoided as they go against expectation
error: non-local `impl` definition, they should be avoided as they go against expectation
--> src/protocol.rs:46:30
|
46 | #[derive(Clone, Copy, Debug, FromPrimitive, ToPrimitive)]
| ^^^^^^^^^^^^^
|
= help: move this `impl` block outside the of the current constant `_IMPL_NUM_FromPrimitive_FOR_RequestType`
= note: an `impl` definition is non-local if it is nested inside an item and may impact type checking outside of that item. This can be the case if neither the trait or the self type are at the same nesting level as the `impl`
= note: one exception to the rule are anon-const (`const _: () = { ... }`) at top-level module and anon-const at the same nesting as the trait or type
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
= note: the derive macro `FromPrimitive` may come from an old version of the `num_derive` crate, try updating your dependency with `cargo update -p num_derive`
= note: `-D non-local-definitions` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(non_local_definitions)]`
= note: this error originates in the derive macro `FromPrimitive` (in Nightly builds, run with -Z macro-backtrace for more info)
Check failure on line 101 in src/ffi.rs
github-actions / clippy
field `addr_type` is never read
error: field `addr_type` is never read
--> src/ffi.rs:101:9
|
98 | pub struct Hostent {
| ------- field in this struct
...
101 | pub addr_type: i32,
| ^^^^^^^^^
|
= note: `Hostent` has derived impls for the traits `Debug` and `Clone`, but these are intentionally ignored during dead code analysis
= note: `-D dead-code` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(dead_code)]`
Loading