Skip to content

Commit

Permalink
Make lints more strict
Browse files Browse the repository at this point in the history
  • Loading branch information
bash committed Jan 23, 2024
1 parent f857ae7 commit 03ee519
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
13 changes: 13 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,19 @@ static_assertions = "1.1.0"
[target.'cfg(unix)'.dev-dependencies]
pty-utils = { path = "crates/pty-utils" }

[lints.rust]
missing_debug_implementations = "warn"
missing_docs = "warn"

[lints.clippy]
unimplemented = "warn"
undocumented_unsafe_blocks = "deny"
dbg_macro = "warn"
exhaustive_enums = "warn"
exhaustive_structs = "warn"
unwrap_used = "deny"
use_debug = "warn"

[features]
__test_unsupported = []

Expand Down
3 changes: 2 additions & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![deny(clippy::undocumented_unsafe_blocks)]
#![cfg_attr(docsrs, feature(doc_cfg))]

//! Provides a handle to the terminal of the current process that is both readable and writable.
Expand Down Expand Up @@ -217,6 +216,8 @@ struct StdioLocks {
stderr_lock: Option<io::StderrLock<'static>>,
}

/// Guard for raw mode on the terminal, disables raw mode on drop.
/// Can be crated using [`TerminalLock::enable_raw_mode`].
#[derive(Debug)]
pub struct RawModeGuard<'a>(imp::RawModeGuard<'a>);

Expand Down

0 comments on commit 03ee519

Please sign in to comment.