mirror of
https://github.com/pezkuwichain/serde.git
synced 2026-06-23 18:51:04 +00:00
Opt in to clippy_pedantic lints
This commit is contained in:
+31
-6
@@ -91,12 +91,37 @@
|
|||||||
#![cfg_attr(feature = "unstable", feature(nonzero, specialization))]
|
#![cfg_attr(feature = "unstable", feature(nonzero, specialization))]
|
||||||
#![cfg_attr(feature = "alloc", feature(alloc))]
|
#![cfg_attr(feature = "alloc", feature(alloc))]
|
||||||
|
|
||||||
// Whitelisted clippy lints.
|
#![cfg_attr(feature = "cargo-clippy", deny(clippy, clippy_pedantic))]
|
||||||
#![cfg_attr(feature = "cargo-clippy", allow(doc_markdown))]
|
// Whitelisted clippy lints
|
||||||
#![cfg_attr(feature = "cargo-clippy", allow(linkedlist))]
|
#![cfg_attr(feature = "cargo-clippy", allow(
|
||||||
#![cfg_attr(feature = "cargo-clippy", allow(type_complexity))]
|
doc_markdown,
|
||||||
#![cfg_attr(feature = "cargo-clippy", allow(unreadable_literal))]
|
linkedlist,
|
||||||
#![cfg_attr(feature = "cargo-clippy", allow(zero_prefixed_literal))]
|
type_complexity,
|
||||||
|
unreadable_literal,
|
||||||
|
zero_prefixed_literal,
|
||||||
|
))]
|
||||||
|
// Whitelisted clippy_pedantic lints
|
||||||
|
#![cfg_attr(feature = "cargo-clippy", allow(
|
||||||
|
// integer and float ser/de requires these sorts of casts
|
||||||
|
cast_possible_truncation,
|
||||||
|
cast_possible_wrap,
|
||||||
|
cast_precision_loss,
|
||||||
|
cast_sign_loss,
|
||||||
|
// simplifies some macros
|
||||||
|
invalid_upcast_comparisons,
|
||||||
|
// things are often more readable this way
|
||||||
|
option_unwrap_used,
|
||||||
|
result_unwrap_used,
|
||||||
|
shadow_reuse,
|
||||||
|
single_match_else,
|
||||||
|
stutter,
|
||||||
|
use_self,
|
||||||
|
// not practical
|
||||||
|
missing_docs_in_private_items,
|
||||||
|
// alternative is not stable
|
||||||
|
empty_enum,
|
||||||
|
use_debug,
|
||||||
|
))]
|
||||||
|
|
||||||
// Blacklisted Rust lints.
|
// Blacklisted Rust lints.
|
||||||
#![deny(missing_docs, unused_imports)]
|
#![deny(missing_docs, unused_imports)]
|
||||||
|
|||||||
Reference in New Issue
Block a user