Implement sleeping #97
clippy
39 warnings
Details
Results
Message level | Amount |
---|---|
Internal compiler error | 0 |
Error | 0 |
Warning | 39 |
Note | 0 |
Help | 0 |
Versions
- rustc 1.83.0 (90b35a623 2024-11-26)
- cargo 1.83.0 (5ffbef321 2024-10-29)
- clippy 0.1.83 (90b35a6 2024-11-26)
Annotations
Check warning on line 37 in mmheroes-core-rs/tests/common.rs
github-actions / clippy
method `to_string` is never used
warning: method `to_string` is never used
--> mmheroes-core-rs/tests/common.rs:37:12
|
22 | impl TestRendererRequestConsumer {
| -------------------------------- method in this implementation
...
37 | pub fn to_string(&self) -> String {
| ^^^^^^^^^
|
= note: `#[warn(dead_code)]` on by default
Check warning on line 37 in mmheroes-core-rs/tests/common.rs
github-actions / clippy
method `to_string` is never used
warning: method `to_string` is never used
--> mmheroes-core-rs/tests/common.rs:37:12
|
22 | impl TestRendererRequestConsumer {
| -------------------------------- method in this implementation
...
37 | pub fn to_string(&self) -> String {
| ^^^^^^^^^
|
= note: `#[warn(dead_code)]` on by default
Check warning on line 37 in mmheroes-core-rs/tests/common.rs
github-actions / clippy
method `to_string` is never used
warning: method `to_string` is never used
--> mmheroes-core-rs/tests/common.rs:37:12
|
22 | impl TestRendererRequestConsumer {
| -------------------------------- method in this implementation
...
37 | pub fn to_string(&self) -> String {
| ^^^^^^^^^
|
= note: `#[warn(dead_code)]` on by default
Check warning on line 37 in mmheroes-core-rs/tests/common.rs
github-actions / clippy
method `to_string` is never used
warning: method `to_string` is never used
--> mmheroes-core-rs/tests/common.rs:37:12
|
22 | impl TestRendererRequestConsumer {
| -------------------------------- method in this implementation
...
37 | pub fn to_string(&self) -> String {
| ^^^^^^^^^
|
= note: `#[warn(dead_code)]` on by default
Check warning on line 37 in mmheroes-core-rs/tests/common.rs
github-actions / clippy
method `to_string` is never used
warning: method `to_string` is never used
--> mmheroes-core-rs/tests/common.rs:37:12
|
22 | impl TestRendererRequestConsumer {
| -------------------------------- method in this implementation
...
37 | pub fn to_string(&self) -> String {
| ^^^^^^^^^
|
= note: `#[warn(dead_code)]` on by default
Check warning on line 37 in mmheroes-core-rs/tests/common.rs
github-actions / clippy
method `to_string` is never used
warning: method `to_string` is never used
--> mmheroes-core-rs/tests/common.rs:37:12
|
22 | impl TestRendererRequestConsumer {
| -------------------------------- method in this implementation
...
37 | pub fn to_string(&self) -> String {
| ^^^^^^^^^
|
= note: `#[warn(dead_code)]` on by default
Check warning on line 37 in mmheroes-core-rs/tests/common.rs
github-actions / clippy
method `to_string` is never used
warning: method `to_string` is never used
--> mmheroes-core-rs/tests/common.rs:37:12
|
22 | impl TestRendererRequestConsumer {
| -------------------------------- method in this implementation
...
37 | pub fn to_string(&self) -> String {
| ^^^^^^^^^
|
= note: `#[warn(dead_code)]` on by default
Check warning on line 37 in mmheroes-core-rs/tests/common.rs
github-actions / clippy
method `to_string` is never used
warning: method `to_string` is never used
--> mmheroes-core-rs/tests/common.rs:37:12
|
22 | impl TestRendererRequestConsumer {
| -------------------------------- method in this implementation
...
37 | pub fn to_string(&self) -> String {
| ^^^^^^^^^
|
= note: `#[warn(dead_code)]` on by default
Check warning on line 268 in mmheroes-core-rs/src/ui/recording.rs
github-actions / clippy
this expression creates a reference which is immediately dereferenced by the compiler
warning: this expression creates a reference which is immediately dereferenced by the compiler
--> mmheroes-core-rs/src/ui/recording.rs:268:52
|
268 | let mut parser = InputRecordingParser::new(&input);
| ^^^^^^ help: change this to: `input`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
Check warning on line 249 in mmheroes-core-rs/src/ui/recording.rs
github-actions / clippy
this expression creates a reference which is immediately dereferenced by the compiler
warning: this expression creates a reference which is immediately dereferenced by the compiler
--> mmheroes-core-rs/src/ui/recording.rs:249:52
|
249 | let mut parser = InputRecordingParser::new(&input);
| ^^^^^^ help: change this to: `input`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
Check warning on line 203 in mmheroes-core-rs/src/ui/recording.rs
github-actions / clippy
this expression creates a reference which is immediately dereferenced by the compiler
warning: this expression creates a reference which is immediately dereferenced by the compiler
--> mmheroes-core-rs/src/ui/recording.rs:203:52
|
203 | let mut parser = InputRecordingParser::new(&input);
| ^^^^^^ help: change this to: `input`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
= note: `#[warn(clippy::needless_borrow)]` on by default
Check warning on line 124 in mmheroes-core-rs/src/ui/renderer.rs
github-actions / clippy
name `RRC` contains a capitalized acronym
warning: name `RRC` contains a capitalized acronym
--> mmheroes-core-rs/src/ui/renderer.rs:124:12
|
124 | struct RRC {
| ^^^ help: consider making the acronym lowercase, except the initial letter: `Rrc`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#upper_case_acronyms
= note: `#[warn(clippy::upper_case_acronyms)]` on by default
Check warning on line 95 in mmheroes-core-rs/src/ui/screens/train.rs
github-actions / clippy
this function has too many arguments (8/7)
warning: this function has too many arguments (8/7)
--> mmheroes-core-rs/src/ui/screens/train.rs:86:1
|
86 | / fn display_train<R: RendererRequestConsumer>(
87 | | r: &mut Renderer<R>,
88 | | available_actions: &[Action],
89 | | state: &GameState,
... |
94 | | gatecrash: &dyn Fn(&mut Renderer<R>, bool) -> (),
95 | | ) -> WaitingState {
| |_________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments
= note: `#[warn(clippy::too_many_arguments)]` on by default
Check warning on line 95 in mmheroes-core-rs/src/ui/screens/train.rs
github-actions / clippy
this function has too many arguments (8/7)
warning: this function has too many arguments (8/7)
--> mmheroes-core-rs/src/ui/screens/train.rs:86:1
|
86 | / fn display_train<R: RendererRequestConsumer>(
87 | | r: &mut Renderer<R>,
88 | | available_actions: &[Action],
89 | | state: &GameState,
... |
94 | | gatecrash: &dyn Fn(&mut Renderer<R>, bool) -> (),
95 | | ) -> WaitingState {
| |_________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments
= note: `#[warn(clippy::too_many_arguments)]` on by default
Check warning on line 31 in mmheroes-core-rs/src/logic/scene_router/train.rs
github-actions / clippy
large size difference between variants
warning: large size difference between variants
--> mmheroes-core-rs/src/logic/scene_router/train.rs:25:1
|
25 | / pub enum BaltiyskiyRailwayStationScene {
26 | | /// "Ты в Питере, на Балтийском вокзале. Куда направляемся?"
27 | | Prompt(GameState),
| | ----------------- the largest variant contains at least 232 bytes
... |
30 | | CaughtByInspectors,
| | ------------------ the second-largest variant carries no data at all
31 | | }
| |_^ the entire enum is at least 232 bytes
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#large_enum_variant
help: consider boxing the large fields to reduce the total size of the enum
|
27 | Prompt(Box<GameState>),
| ~~~~~~~~~~~~~~
Check warning on line 31 in mmheroes-core-rs/src/logic/scene_router/train.rs
github-actions / clippy
large size difference between variants
warning: large size difference between variants
--> mmheroes-core-rs/src/logic/scene_router/train.rs:25:1
|
25 | / pub enum BaltiyskiyRailwayStationScene {
26 | | /// "Ты в Питере, на Балтийском вокзале. Куда направляемся?"
27 | | Prompt(GameState),
| | ----------------- the largest variant contains at least 232 bytes
... |
30 | | CaughtByInspectors,
| | ------------------ the second-largest variant carries no data at all
31 | | }
| |_^ the entire enum is at least 232 bytes
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#large_enum_variant
help: consider boxing the large fields to reduce the total size of the enum
|
27 | Prompt(Box<GameState>),
| ~~~~~~~~~~~~~~
Check warning on line 5 in mmheroes-core-rs/src/logic/subject_status.rs
github-actions / clippy
manual implementation of an assign operation
warning: manual implementation of an assign operation
--> mmheroes-core-rs/src/logic/subject_status.rs:5:1
|
5 | #[bitfield(u16, debug = false, default = false)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern
= note: this warning originates in the attribute macro `bitfield` (in Nightly builds, run with -Z macro-backtrace for more info)
Check warning on line 5 in mmheroes-core-rs/src/logic/player.rs
github-actions / clippy
manual implementation of an assign operation
warning: manual implementation of an assign operation
--> mmheroes-core-rs/src/logic/player.rs:5:1
|
5 | #[bitfield(u16, debug = true, default = false)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern
= note: this warning originates in the attribute macro `bitfield` (in Nightly builds, run with -Z macro-backtrace for more info)
Check warning on line 5 in mmheroes-core-rs/src/logic/subject_status.rs
github-actions / clippy
manual implementation of an assign operation
warning: manual implementation of an assign operation
--> mmheroes-core-rs/src/logic/subject_status.rs:5:1
|
5 | #[bitfield(u16, debug = false, default = false)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern
= note: this warning originates in the attribute macro `bitfield` (in Nightly builds, run with -Z macro-backtrace for more info)
Check warning on line 19 in mmheroes-core-rs/src/logic/npc/nil.rs
github-actions / clippy
large size difference between variants
warning: large size difference between variants
--> mmheroes-core-rs/src/logic/npc/nil.rs:7:1
|
7 | / pub enum NilInteraction {
8 | | /// "Маладой чилавек, вы мне не паможите решить задачу?
9 | | /// А то я сигодня ни в зуб нагой ..."
10 | | WillYouHelpMe(GameState),
| | ------------------------ the largest variant contains at least 232 bytes
... |
15 | | ThanksHereIsYourMoney(Money),
| | ---------------------------- the second-largest variant contains at least 2 bytes
... |
18 | | DidntWorkOut,
19 | | }
| |_^ the entire enum is at least 232 bytes
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#large_enum_variant
help: consider boxing the large fields to reduce the total size of the enum
|
10 | WillYouHelpMe(Box<GameState>),
| ~~~~~~~~~~~~~~
Check warning on line 5 in mmheroes-core-rs/src/logic/player.rs
github-actions / clippy
manual implementation of an assign operation
warning: manual implementation of an assign operation
--> mmheroes-core-rs/src/logic/player.rs:5:1
|
5 | #[bitfield(u16, debug = true, default = false)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern
= note: this warning originates in the attribute macro `bitfield` (in Nightly builds, run with -Z macro-backtrace for more info)
Check warning on line 25 in mmheroes-core-rs/src/logic/npc/andrew.rs
github-actions / clippy
large size difference between variants
warning: large size difference between variants
--> mmheroes-core-rs/src/logic/npc/andrew.rs:4:1
|
4 | / pub enum AndrewInteraction {
5 | | /// "Обратиться к Эндрю за помощью?"
6 | | PromptHelpFromAndrew(GameState),
| | ------------------------------- the largest variant contains at least 232 bytes
... |
12 | |/ ScorePrediction {
13 | || subject: Subject,
14 | || prediction: u8,
15 | || },
| ||_____- the second-largest variant contains at least 2 bytes
... |
24 | | AndrewIgnoresYou,
25 | | }
| |__^ the entire enum is at least 232 bytes
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#large_enum_variant
= note: `#[warn(clippy::large_enum_variant)]` on by default
help: consider boxing the large fields to reduce the total size of the enum
|
6 | PromptHelpFromAndrew(Box<GameState>),
| ~~~~~~~~~~~~~~
Check warning on line 19 in mmheroes-core-rs/src/logic/npc/nil.rs
github-actions / clippy
large size difference between variants
warning: large size difference between variants
--> mmheroes-core-rs/src/logic/npc/nil.rs:7:1
|
7 | / pub enum NilInteraction {
8 | | /// "Маладой чилавек, вы мне не паможите решить задачу?
9 | | /// А то я сигодня ни в зуб нагой ..."
10 | | WillYouHelpMe(GameState),
| | ------------------------ the largest variant contains at least 232 bytes
... |
15 | | ThanksHereIsYourMoney(Money),
| | ---------------------------- the second-largest variant contains at least 2 bytes
... |
18 | | DidntWorkOut,
19 | | }
| |_^ the entire enum is at least 232 bytes
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#large_enum_variant
help: consider boxing the large fields to reduce the total size of the enum
|
10 | WillYouHelpMe(Box<GameState>),
| ~~~~~~~~~~~~~~
Check warning on line 6 in mmheroes-core-rs/src/logic/game_state.rs
github-actions / clippy
manual implementation of an assign operation
warning: manual implementation of an assign operation
--> mmheroes-core-rs/src/logic/game_state.rs:6:1
|
6 | #[bitfield(u32, debug = false, default = false)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern
= note: `#[warn(clippy::assign_op_pattern)]` on by default
= note: this warning originates in the attribute macro `bitfield` (in Nightly builds, run with -Z macro-backtrace for more info)
Check warning on line 25 in mmheroes-core-rs/src/logic/npc/andrew.rs
github-actions / clippy
large size difference between variants
warning: large size difference between variants
--> mmheroes-core-rs/src/logic/npc/andrew.rs:4:1
|
4 | / pub enum AndrewInteraction {
5 | | /// "Обратиться к Эндрю за помощью?"
6 | | PromptHelpFromAndrew(GameState),
| | ------------------------------- the largest variant contains at least 232 bytes
... |
12 | |/ ScorePrediction {
13 | || subject: Subject,
14 | || prediction: u8,
15 | || },
| ||_____- the second-largest variant contains at least 2 bytes
... |
24 | | AndrewIgnoresYou,
25 | | }
| |__^ the entire enum is at least 232 bytes
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#large_enum_variant
= note: `#[warn(clippy::large_enum_variant)]` on by default
help: consider boxing the large fields to reduce the total size of the enum
|
6 | PromptHelpFromAndrew(Box<GameState>),
| ~~~~~~~~~~~~~~