Update serde_derive to tool attrs

This commit is contained in:
David Tolnay 2020-04-05 21:00:52 -07:00
parent d1564525ad
commit 1b35c9e27e
No known key found for this signature in database
GPG Key ID: F9BA143B95FF6D82
2 changed files with 29 additions and 38 deletions

View File

@ -21,9 +21,7 @@ pub fn wrap_in_const(
use #path as _serde;
},
None => quote! {
#[allow(unknown_lints)]
#[cfg_attr(feature = "cargo-clippy", allow(useless_attribute))]
#[allow(rust_2018_idioms)]
#[allow(rust_2018_idioms, clippy::useless_attribute)]
extern crate serde as _serde;
},
};

View File

@ -15,44 +15,37 @@
#![doc(html_root_url = "https://docs.rs/serde_derive/1.0.106")]
#![allow(unknown_lints, bare_trait_objects)]
#![cfg_attr(feature = "cargo-clippy", allow(renamed_and_removed_lints))]
#![cfg_attr(feature = "cargo-clippy", deny(clippy, clippy_pedantic))]
#![deny(clippy::all, clippy::pedantic)]
// Ignored clippy lints
#![cfg_attr(
feature = "cargo-clippy",
allow(
cognitive_complexity,
enum_variant_names,
needless_pass_by_value,
redundant_field_names,
too_many_arguments,
trivially_copy_pass_by_ref,
used_underscore_binding,
wildcard_in_or_patterns,
)
#![allow(
clippy::cognitive_complexity,
clippy::enum_variant_names,
clippy::needless_pass_by_value,
clippy::redundant_field_names,
clippy::too_many_arguments,
clippy::trivially_copy_pass_by_ref,
clippy::used_underscore_binding,
clippy::wildcard_in_or_patterns
)]
// Ignored clippy_pedantic lints
#![cfg_attr(
feature = "cargo-clippy",
allow(
cast_possible_truncation,
checked_conversions,
doc_markdown,
enum_glob_use,
filter_map,
indexing_slicing,
items_after_statements,
match_same_arms,
module_name_repetitions,
must_use_candidate,
similar_names,
single_match_else,
struct_excessive_bools,
too_many_lines,
unseparated_literal_suffix,
use_self,
wildcard_imports,
)
#![allow(
clippy::cast_possible_truncation,
clippy::checked_conversions,
clippy::doc_markdown,
clippy::enum_glob_use,
clippy::filter_map,
clippy::indexing_slicing,
clippy::items_after_statements,
clippy::match_same_arms,
clippy::module_name_repetitions,
clippy::must_use_candidate,
clippy::similar_names,
clippy::single_match_else,
clippy::struct_excessive_bools,
clippy::too_many_lines,
clippy::unseparated_literal_suffix,
clippy::use_self,
clippy::wildcard_imports
)]
// The `quote!` macro requires deep recursion.
#![recursion_limit = "512"]