Skip to content

Commit

Permalink
Update crate-level lints (#225)
Browse files Browse the repository at this point in the history
  • Loading branch information
uklotzde authored Oct 3, 2023
1 parent c672636 commit 4232cf6
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 8 deletions.
6 changes: 3 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,16 +35,16 @@ repos:
hooks:
- id: markdownlint-cli2
- repo: https://github.com/shellcheck-py/shellcheck-py
rev: v0.9.0.5
rev: v0.9.0.6
hooks:
- id: shellcheck
- repo: https://github.com/codespell-project/codespell
rev: v2.2.5
rev: v2.2.6
hooks:
- id: codespell
args: [--ignore-words=.codespellignore]
- repo: https://github.com/sirosen/check-jsonschema
rev: 0.26.3
rev: 0.27.0
hooks:
- id: check-github-actions
- id: check-github-workflows
Expand Down
2 changes: 1 addition & 1 deletion src/codec/tcp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ mod tests {
assert_eq!(buf[5], 0x6);
assert_eq!(buf[6], UNIT_ID);

_ = buf.split_to(7);
drop(buf.split_to(7));
let pdu: Bytes = req.try_into().unwrap();
assert_eq!(buf, pdu);
}
Expand Down
12 changes: 8 additions & 4 deletions src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,15 +1,19 @@
// SPDX-FileCopyrightText: Copyright (c) 2017-2023 slowtec GmbH <[email protected]>
// SPDX-License-Identifier: MIT OR Apache-2.0

#![warn(rustdoc::broken_intra_doc_links)]
#![doc = include_str!("../README.md")]
#![warn(rust_2018_idioms)]
#![warn(rust_2021_compatibility)]
// Opt-in for allowed-by-default lints (in alphabetical order)
// See also: <https://doc.rust-lang.org/rustc/lints>
#![warn(future_incompatible)]
#![warn(let_underscore)]
#![warn(missing_debug_implementations)]
//#![warn(missing_docs)] // TODO
#![warn(rust_2018_idioms)]
#![warn(rust_2021_compatibility)]
#![warn(unreachable_pub)]
#![warn(unsafe_code)]
#![warn(rustdoc::broken_intra_doc_links)]
#![warn(unused)]
// Clippy lints
#![warn(clippy::pedantic)]
// Additional restrictions
#![warn(clippy::clone_on_ref_ptr)]
Expand Down

0 comments on commit 4232cf6

Please sign in to comment.