feat: enhance strictness of Rust compiler settings and improve code quality by treating warnings as errors

This commit is contained in:
asepharyana
2026-07-13 06:22:31 +07:00
parent 3f5f27c339
commit 5334c2501b
20 changed files with 95 additions and 108 deletions
-1
View File
@@ -6,7 +6,6 @@ pub mod editor;
pub mod effort;
pub mod key_input;
pub mod mcp;
pub mod workflow;
pub mod quit_confirm;
pub mod rewind;
-37
View File
@@ -1,37 +0,0 @@
//! Workflow-mode helper logic for the TUI workflow overlay.
//!
//! Flow: exposes a dismiss handler invoked by a keybinding to close the
//! workflow overlay, and a status query used elsewhere to check whether
//! it is currently showing.
use crate::app::state::rest::AppStateRest;
use crate::app::state::types::Overlay;
/// Close the workflow overlay if it is the currently active overlay.
///
/// Flow: check `state.misc.overlay == Overlay::Workflow`, reset to `Overlay::None`
/// if so, then mark state dirty regardless.
///
/// Why: no-ops safely if another overlay is showing, so it can be called
/// unconditionally from a dismiss keybinding.
///
/// Return: nothing; mutates `state.misc.overlay` and `state.dirty` in place.
pub fn handle_workflow_dismiss(state: &mut AppStateRest) {
if state.misc.overlay == Overlay::Workflow {
state.misc.overlay = Overlay::None;
}
state.dirty = true;
}
/// Report whether the workflow overlay is currently displayed.
///
/// Flow: compare `state.misc.overlay` against `Overlay::Workflow`.
///
/// Return: `"active"` if the workflow overlay is shown, `"idle"` otherwise.
pub fn workflow_status(state: &AppStateRest) -> &str {
if state.misc.overlay == Overlay::Workflow {
"active"
} else {
"idle"
}
}