warning: unexpected `cfg` condition name: `serde_build_from_git`
--> serde_derive_internals/lib.rs:45:12
|
45 | #[cfg_attr(serde_build_from_git, path = "../serde_derive/src/internals/mod.rs")]
| ^^^^^^^^^^^^^^^^^^^^
|
= help: expected names are: `clippy`, `debug_assertions`, `doc`, `docsrs`, `doctest`, `feature`, `miri`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `rustfmt`, `sanitize`, `sanitizer_cfi_generalize_pointers`, `sanitizer_cfi_normalize_integers`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `test`, `ub_checks`, `unix`, `windows`
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(serde_build_from_git)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
= note: `#[warn(unexpected_cfgs)]` on by default
warning: unexpected `cfg` condition name: `serde_build_from_git`
--> serde_derive_internals/lib.rs:46:16
|
46 | #[cfg_attr(not(serde_build_from_git), path = "src/mod.rs")]
| ^^^^^^^^^^^^^^^^^^^^
|
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(serde_build_from_git)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition value: `deserialize_in_place`
--> serde_derive_internals/src/attr.rs:276:11
|
276 | #[cfg(feature = "deserialize_in_place")]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove the condition
|
= note: no expected values for `feature`
= help: consider adding `deserialize_in_place` as a feature in `Cargo.toml`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition name: `exhaustive`
--> serde_derive_internals/src/attr.rs:1797:31
|
1797 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ^^^^^^^^^^
|
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(exhaustive)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition name: `exhaustive`
--> serde_derive_internals/src/receiver.rs:110:35
|
110 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ^^^^^^^^^^
|
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(exhaustive)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition name: `exhaustive`
--> serde_derive_internals/src/receiver.rs:181:47
|
181 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ^^^^^^^^^^
|
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(exhaustive)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition name: `exhaustive`
--> serde_derive_internals/src/receiver.rs:210:35
|
210 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ^^^^^^^^^^
|
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(exhaustive)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition name: `exhaustive`
--> serde_derive_internals/src/receiver.rs:231:43
|
231 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ^^^^^^^^^^
|
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(exhaustive)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition name: `exhaustive`
--> serde_derive/src/lib.rs:62:23
|
62 | #![cfg_attr(all(test, exhaustive), feature(non_exhaustive_omitted_patterns_lint))]
| ^^^^^^^^^^
|
= help: expected names are: `clippy`, `debug_assertions`, `doc`, `docsrs`, `doctest`, `feature`, `miri`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `rustfmt`, `sanitize`, `sanitizer_cfi_generalize_pointers`, `sanitizer_cfi_normalize_integers`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `test`, `ub_checks`, `unix`, `windows`
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(exhaustive)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
= note: `#[warn(unexpected_cfgs)]` on by default
warning: unexpected `cfg` condition name: `exhaustive`
--> serde_derive/src/internals/attr.rs:1797:31
|
1797 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ^^^^^^^^^^
|
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(exhaustive)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition name: `exhaustive`
--> serde_derive/src/internals/receiver.rs:110:35
|
110 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ^^^^^^^^^^
|
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(exhaustive)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition name: `exhaustive`
--> serde_derive/src/internals/receiver.rs:181:47
|
181 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ^^^^^^^^^^
|
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(exhaustive)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition name: `exhaustive`
--> serde_derive/src/internals/receiver.rs:210:35
|
210 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ^^^^^^^^^^
|
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(exhaustive)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition name: `exhaustive`
--> serde_derive/src/internals/receiver.rs:231:43
|
231 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ^^^^^^^^^^
|
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(exhaustive)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition name: `exhaustive`
--> serde_derive/src/bound.rs:147:39
|
147 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ^^^^^^^^^^
|
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(exhaustive)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition name: `exhaustive`
--> serde_derive/src/bound.rs:199:51
|
199 | ... #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ^^^^^^^^^^
|
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(exhaustive)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition name: `exhaustive`
--> serde_derive/src/bound.rs:228:39
|
228 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ^^^^^^^^^^
|
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(exhaustive)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
warning: unexpected `cfg` condition name: `systemtime_checked_add`
--> test_suite/tests/test_de_error.rs:1527:7
|
1527 | #[cfg(systemtime_checked_add)]
| ^^^^^^^^^^^^^^^^^^^^^^
|
= help: expected names are: `clippy`, `debug_assertions`, `doc`, `docsrs`, `doctest`, `feature`, `miri`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `rustfmt`, `sanitize`, `sanitizer_cfi_generalize_pointers`, `sanitizer_cfi_normalize_integers`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `test`, `ub_checks`, `unix`, `windows`
= help: consider using a Cargo feature instead or adding `println!("cargo::rustc-check-cfg=cfg(systemtime_checked_add)");` to the top of the `build.rs`
= note: see <https://doc.rust-lang.org/nightly/cargo/reference/build-scripts.html#rustc-check-cfg> for more information about checking conditional configuration
= note: `#[warn(unexpected_cfgs)]` on by default
warning: usage of a legacy numeric method
--> serde_derive/src/ser.rs:292:51
|
292 | assert!(fields.len() as u64 <= u64::from(u32::max_value()));
| ^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants
= note: `#[warn(clippy::legacy_numeric_constants)]` on by default
help: use the associated constant instead
|
292 | assert!(fields.len() as u64 <= u64::from(u32::MAX));
| ~~~
warning: usage of a legacy numeric method
--> serde_derive/src/ser.rs:400:53
|
400 | assert!(variants.len() as u64 <= u64::from(u32::max_value()));
| ^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants
help: use the associated constant instead
|
400 | assert!(variants.len() as u64 <= u64::from(u32::MAX));
| ~~~
warning: usage of a legacy numeric method
--> test_suite/tests/test_de_error.rs:1462:29
|
1462 | Token::U64(u64::max_value()),
| ^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants
= note: `-W clippy::legacy-numeric-constants` implied by `-W clippy::all`
= help: to override `-W clippy::all` add `#[allow(clippy::legacy_numeric_constants)]`
help: use the associated constant instead
|
1462 | Token::U64(u64::MAX),
| ~~~
warning: usage of a legacy numeric method
--> test_suite/tests/test_de_error.rs:1479:29
|
1479 | Token::U64(u64::max_value()),
| ^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants
help: use the associated constant instead
|
1479 | Token::U64(u64::MAX),
| ~~~
warning: usage of a legacy numeric method
--> test_suite/tests/test_de_error.rs:1493:29
|
1493 | Token::U64(u64::max_value()),
| ^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants
help: use the associated constant instead
|
1493 | Token::U64(u64::MAX),
| ~~~
warning: usage of a legacy numeric method
--> test_suite/tests/test_de_error.rs:1510:29
|
1510 | Token::U64(u64::max_value()),
| ^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants
help: use the associated constant instead
|
1510 | Token::U64(u64::MAX),
| ~~~
New warning since nightly-2024-03-03:
warning: serde_derive/Cargo.toml: no edition set: defaulting to the 2015 edition while 2018 is compatible with `rust-version`
warning: serde_derive_internals/Cargo.toml: no edition set: defaulting to the 2015 edition while 2018 is compatible with `rust-version`
warning: serde_derive_internals/Cargo.toml: `default-features` is
ignored for syn, since `default-features` was not specified for
`workspace.dependencies.syn`, this could become a hard error in the
future
warning: the lint level must be set on the whole match
--> serde_derive/src/internals/attr.rs:1855:9
|
1854 | #[cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ------------------------------- remove this attribute
1855 | _ => {}
| ^
|
= help: it no longer has any effect to set the lint level on an individual match arm
help: set the lint level on the whole match
|
1796 + #[deny(non_exhaustive_omitted_patterns)]
1797 | match ty {
|
warning: the lint level must be set on the whole match
--> serde_derive/src/internals/receiver.rs:151:13
|
150 | #[cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ------------------------------- remove this attribute
151 | _ => {}
| ^
|
= help: it no longer has any effect to set the lint level on an individual match arm
help: set the lint level on the whole match
|
109 + #[deny(non_exhaustive_omitted_patterns)]
110 | match ty {
|
warning: the lint level must be set on the whole match
--> serde_derive/src/internals/receiver.rs:188:25
|
187 | #[cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ------------------------------- remove this attribute
188 | _ => {}
| ^
|
= help: it no longer has any effect to set the lint level on an individual match arm
help: set the lint level on the whole match
|
180 + #[deny(non_exhaustive_omitted_patterns)]
181 | match arg {
|
warning: the lint level must be set on the whole match
--> serde_derive/src/internals/receiver.rs:213:13
|
212 | #[cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ------------------------------- remove this attribute
213 | _ => {}
| ^
|
= help: it no longer has any effect to set the lint level on an individual match arm
help: set the lint level on the whole match
|
209 + #[deny(non_exhaustive_omitted_patterns)]
210 | match bound {
|
warning: the lint level must be set on the whole match
--> serde_derive/src/internals/receiver.rs:239:21
|
238 | #[cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ------------------------------- remove this attribute
239 | _ => {}
| ^
|
= help: it no longer has any effect to set the lint level on an individual match arm
help: set the lint level on the whole match
|
230 + #[deny(non_exhaustive_omitted_patterns)]
231 | match predicate {
|
warning: the lint level must be set on the whole match
--> serde_derive/src/bound.rs:185:17
|
184 | #[cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ------------------------------- remove this attribute
185 | _ => {}
| ^
|
= help: it no longer has any effect to set the lint level on an individual match arm
help: set the lint level on the whole match
|
146 + #[deny(non_exhaustive_omitted_patterns)]
147 | match ty {
|
warning: the lint level must be set on the whole match
--> serde_derive/src/bound.rs:209:29
|
207 | ... deny(non_exhaustive_omitted_patterns)
| ------------------------------- remove this attribute
208 | ... )]
209 | ... _ => {}
| ^
|
= help: it no longer has any effect to set the lint level on an individual match arm
help: set the lint level on the whole match
|
198 + #[deny(non_exhaustive_omitted_patterns)]
199 | match arg {
|
warning: the lint level must be set on the whole match
--> serde_derive/src/bound.rs:234:17
|
233 | #[cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ------------------------------- remove this attribute
234 | _ => {}
| ^
|
= help: it no longer has any effect to set the lint level on an individual match arm
help: set the lint level on the whole match
|
230 + #[deny(non_exhaustive_omitted_patterns)]
231 | match bound {
|
error: some variants are not matched explicitly
--> serde_derive/src/internals/attr.rs:1823:31
|
1823 | match arg {
| ^^^ patterns `&GenericArgument::Const(_)`, `&GenericArgument::AssocConst(_)` and `&GenericArgument::Constraint(_)` not covered
|
= help: ensure that all variants are matched explicitly by adding the suggested match arms
= note: the matched value is of type `&GenericArgument` and the `non_exhaustive_omitted_patterns` attribute was found
note: the lint level is defined here
--> serde_derive/src/internals/attr.rs:1797:49
|
1797 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
warning: accessing first element with `variant.fields.get(0)`
--> serde_derive/src/de.rs:1843:27
|
1843 | let default = variant.fields.get(0).map(|field| {
| ^^^^^^^^^^^^^^^^^^^^^ help: try: `variant.fields.first()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first
= note: `-W clippy::get-first` implied by `-W clippy::all`
= help: to override `-W clippy::all` add `#[allow(clippy::get_first)]`
warning: accessing first element with `variant.fields.get(0)`
--> serde_derive/src/de.rs:1888:27
|
1888 | let default = variant.fields.get(0).map(|field| {
| ^^^^^^^^^^^^^^^^^^^^^ help: try: `variant.fields.first()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first
`expr` is of type serde_derive::fragment::Expr, which can be
interpolated directly in any expression position. It does not
need to be nested in another set of braces.
warning: matching over `()` is more explicit
--> serde_derive/src/internals/attr.rs:710:33
|
710 | (Some((untagged_tokens, _)), Some((tag_tokens, _)), None) => {
| ^ help: use `()` instead of `_`: `()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ignored_unit_patterns
= note: `-W clippy::ignored-unit-patterns` implied by `-W clippy::pedantic`
warning: matching over `()` is more explicit
--> serde_derive/src/internals/attr.rs:721:33
|
721 | (Some((untagged_tokens, _)), None, Some((content_tokens, _))) => {
| ^ help: use `()` instead of `_`: `()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ignored_unit_patterns
warning: matching over `()` is more explicit
--> serde_derive/src/internals/attr.rs:728:33
|
728 | (Some((untagged_tokens, _)), Some((tag_tokens, _)), Some((content_tokens, _))) => {
| ^ help: use `()` instead of `_`: `()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ignored_unit_patterns
warning: matching over `()` is more explicit
--> serde_derive/src/internals/attr.rs:750:44
|
750 | (_, Some((field_identifier_tokens, _)), Some((variant_identifier_tokens, _))) => {
| ^ help: use `()` instead of `_`: `()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ignored_unit_patterns
warning: matching over `()` is more explicit
--> serde_derive/src/internals/attr.rs:750:82
|
750 | (_, Some((field_identifier_tokens, _)), Some((variant_identifier_tokens, _))) => {
| ^ help: use `()` instead of `_`: `()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ignored_unit_patterns