mirror of
https://github.com/serde-rs/serde.git
synced 2025-09-28 05:21:05 +00:00
905 Commits
Author | SHA1 | Message | Date | |
---|---|---|---|---|
![]() |
ff3aee490a
|
Release 1.0.221 | ||
![]() |
be255d62c8
|
Release 1.0.220 | ||
![]() |
f669f16127
|
Restore __deserialize_content optimization | ||
![]() |
8909fc0c60
|
Enforce derive cannot be used against serde_core
Even for a simple data structure that would ordinarily expand to an impl that only refers to the public Serde traits without serde::__private, we still disallow a (renamed) serde_core dependency. This leaves the liberty to new usage of private helpers in such impls over time. For example, similar to the optimization of the standard library's derive(Debug) that introduced debug_struct_field1_finish to improve compile time of derived impls. |
||
![]() |
2130ba5788
|
Ignore mismatched_lifetime_syntaxes lint
warning: lifetime flowing from input to output with different syntax can be confusing --> serde/src/private/de.rs:266:23 | 266 | fn unexpected(&self) -> Unexpected { | ^^^^^ ---------- the lifetime gets resolved as `'_` | | | this lifetime flows to the output | = note: `#[warn(mismatched_lifetime_syntaxes)]` on by default help: one option is to remove the lifetime for references and use the anonymous lifetime for paths | 266 | fn unexpected(&self) -> Unexpected<'_> { | ++++ warning: lifetime flowing from input to output with different syntax can be confusing --> serde/src/private/mod.rs:27:35 | 27 | pub fn from_utf8_lossy(bytes: &[u8]) -> Cow<str> { | ^^^^^ -------- the lifetime gets resolved as `'_` | | | this lifetime flows to the output | help: one option is to remove the lifetime for references and use the anonymous lifetime for paths | 27 | pub fn from_utf8_lossy(bytes: &[u8]) -> Cow<'_, str> { | +++ warning: lifetime flowing from input to output with different syntax can be confusing --> serde_derive/src/internals/attr.rs:612:23 | 612 | pub fn serde_path(&self) -> Cow<syn::Path> { | ^^^^^ -------------- the lifetime gets resolved as `'_` | | | this lifetime flows to the output | = note: `#[warn(mismatched_lifetime_syntaxes)]` on by default help: one option is to remove the lifetime for references and use the anonymous lifetime for paths | 612 | pub fn serde_path(&self) -> Cow<'_, syn::Path> { | +++ warning: lifetime flowing from input to output with different syntax can be confusing --> serde_derive/src/internals/case.rs:45:37 | 45 | pub fn from_str(rename_all_str: &str) -> Result<Self, ParseError> { | ^^^^ ---------- the lifetime gets resolved as `'_` | | | this lifetime flows to the output | help: one option is to remove the lifetime for references and use the anonymous lifetime for paths | 45 | pub fn from_str(rename_all_str: &str) -> Result<Self, ParseError<'_>> { | ++++ warning: lifetime flowing from input to output with different syntax can be confusing --> serde_derive/src/de.rs:3228:13 | 3228 | params: &Parameters, | ^^^^^^^^^^^ this lifetime flows to the output 3229 | ) -> ( 3230 | DeImplGenerics, | -------------- the lifetimes get resolved as `'_` 3231 | DeTypeGenerics, | -------------- the lifetimes get resolved as `'_` 3232 | syn::TypeGenerics, | ----------------- the lifetimes get resolved as `'_` 3233 | Option<&syn::WhereClause>, | ----------------- the lifetimes get resolved as `'_` | help: one option is to remove the lifetime for references and use the anonymous lifetime for paths | 3230 ~ DeImplGenerics<'_>, 3231 ~ DeTypeGenerics<'_>, 3232 ~ syn::TypeGenerics<'_>, | |
||
![]() |
88da17ca21 |
chore: fix the incorrect symbol
Signed-off-by: jimmycathy <clonecode@outlook.com> |
||
![]() |
e3a4165363 | Switch all crates to edition 2021 | ||
![]() |
49d098debd
|
Release 1.0.219 | ||
![]() |
40f1d19dbe
|
Wrap dummy.rs to 80 columns | ||
![]() |
168b6cf789
|
fix clippy absolute paths warning | ||
![]() |
a8bdd17333
|
Remove unused Punctuated import
warning: unused import: `syn::punctuated::Punctuated` --> serde_derive/src/internals/receiver.rs:5:5 | 5 | use syn::punctuated::Punctuated; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = note: `#[warn(unused_imports)]` on by default Left by the previous commit. - let segments = mem::replace(&mut path.segments, Punctuated::new()); + let segments = mem::take(&mut path.segments); |
||
![]() |
1c9601358b
|
Resolve mem_replace_with_default clippy lint
warning: replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take` --> serde_derive/src/internals/receiver.rs:52:24 | 52 | let segments = mem::replace(&mut path.segments, Punctuated::new()); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using: `std::mem::take(&mut path.segments)` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#mem_replace_with_default = note: `-W clippy::mem-replace-with-default` implied by `-W clippy::all` = help: to override `-W clippy::all` add `#[allow(clippy::mem_replace_with_default)]` |
||
![]() |
f0d1ae08f3
|
Ignore elidable_lifetime_names pedantic clippy lint
warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:124:6 | 124 | impl<'de, E> IntoDeserializer<'de, E> for () | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names = note: `-W clippy::elidable-lifetime-names` implied by `-W clippy::pedantic` = help: to override `-W clippy::pedantic` add `#[allow(clippy::elidable_lifetime_names)]` help: elide the lifetimes | 124 - impl<'de, E> IntoDeserializer<'de, E> for () 124 + impl<E> IntoDeserializer<'_, E> for () | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:178:6 | 178 | impl<'de, E> IntoDeserializer<'de, E> for UnitDeserializer<E> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 178 - impl<'de, E> IntoDeserializer<'de, E> for UnitDeserializer<E> 178 + impl<E> IntoDeserializer<'_, E> for UnitDeserializer<E> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:207:6 | 207 | impl<'de, E> IntoDeserializer<'de, E> for ! | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 207 - impl<'de, E> IntoDeserializer<'de, E> for ! 207 + impl<E> IntoDeserializer<'_, E> for ! | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:240:6 | 240 | impl<'de, E> IntoDeserializer<'de, E> for NeverDeserializer<E> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 240 - impl<'de, E> IntoDeserializer<'de, E> for NeverDeserializer<E> 240 + impl<E> IntoDeserializer<'_, E> for NeverDeserializer<E> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:351:6 | 351 | impl<'de, E> IntoDeserializer<'de, E> for u32 | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 351 - impl<'de, E> IntoDeserializer<'de, E> for u32 351 + impl<E> IntoDeserializer<'_, E> for u32 | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:406:6 | 406 | impl<'de, E> IntoDeserializer<'de, E> for U32Deserializer<E> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 406 - impl<'de, E> IntoDeserializer<'de, E> for U32Deserializer<E> 406 + impl<E> IntoDeserializer<'_, E> for U32Deserializer<E> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:451:6 | 451 | impl<'de, 'a, E> IntoDeserializer<'de, E> for &'a str | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 451 - impl<'de, 'a, E> IntoDeserializer<'de, E> for &'a str 451 + impl<'a, E> IntoDeserializer<'_, E> for &'a str | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:472:11 | 472 | impl<'de, 'a, E> de::Deserializer<'de> for StrDeserializer<'a, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 472 - impl<'de, 'a, E> de::Deserializer<'de> for StrDeserializer<'a, E> 472 + impl<'de, E> de::Deserializer<'de> for StrDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'de, 'a --> serde/src/de/value.rs:506:6 | 506 | impl<'de, 'a, E> IntoDeserializer<'de, E> for StrDeserializer<'a, E> | ^^^ ^^ ^^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 506 - impl<'de, 'a, E> IntoDeserializer<'de, E> for StrDeserializer<'a, E> 506 + impl<E> IntoDeserializer<'_, E> for StrDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:517:11 | 517 | impl<'de, 'a, E> de::EnumAccess<'de> for StrDeserializer<'a, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 517 - impl<'de, 'a, E> de::EnumAccess<'de> for StrDeserializer<'a, E> 517 + impl<'de, E> de::EnumAccess<'de> for StrDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:532:6 | 532 | impl<'a, E> Debug for StrDeserializer<'a, E> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 532 - impl<'a, E> Debug for StrDeserializer<'a, E> { 532 + impl<E> Debug for StrDeserializer<'_, E> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:622:6 | 622 | impl<'de, E> Debug for BorrowedStrDeserializer<'de, E> { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 622 - impl<'de, E> Debug for BorrowedStrDeserializer<'de, E> { 622 + impl<E> Debug for BorrowedStrDeserializer<'_, E> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:653:6 | 653 | impl<'de, E> IntoDeserializer<'de, E> for String | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 653 - impl<'de, E> IntoDeserializer<'de, E> for String 653 + impl<E> IntoDeserializer<'_, E> for String | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:711:6 | 711 | impl<'de, E> IntoDeserializer<'de, E> for StringDeserializer<E> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 711 - impl<'de, E> IntoDeserializer<'de, E> for StringDeserializer<E> 711 + impl<E> IntoDeserializer<'_, E> for StringDeserializer<E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:759:6 | 759 | impl<'a, E> Clone for CowStrDeserializer<'a, E> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 759 - impl<'a, E> Clone for CowStrDeserializer<'a, E> { 759 + impl<E> Clone for CowStrDeserializer<'_, E> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:770:6 | 770 | impl<'de, 'a, E> IntoDeserializer<'de, E> for Cow<'a, str> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 770 - impl<'de, 'a, E> IntoDeserializer<'de, E> for Cow<'a, str> 770 + impl<'a, E> IntoDeserializer<'_, E> for Cow<'a, str> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:793:11 | 793 | impl<'de, 'a, E> de::Deserializer<'de> for CowStrDeserializer<'a, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 793 - impl<'de, 'a, E> de::Deserializer<'de> for CowStrDeserializer<'a, E> 793 + impl<'de, E> de::Deserializer<'de> for CowStrDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'de, 'a --> serde/src/de/value.rs:831:6 | 831 | impl<'de, 'a, E> IntoDeserializer<'de, E> for CowStrDeserializer<'a, E> | ^^^ ^^ ^^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 831 - impl<'de, 'a, E> IntoDeserializer<'de, E> for CowStrDeserializer<'a, E> 831 + impl<E> IntoDeserializer<'_, E> for CowStrDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:843:11 | 843 | impl<'de, 'a, E> de::EnumAccess<'de> for CowStrDeserializer<'a, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 843 - impl<'de, 'a, E> de::EnumAccess<'de> for CowStrDeserializer<'a, E> 843 + impl<'de, E> de::EnumAccess<'de> for CowStrDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:859:6 | 859 | impl<'a, E> Debug for CowStrDeserializer<'a, E> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 859 - impl<'a, E> Debug for CowStrDeserializer<'a, E> { 859 + impl<E> Debug for CowStrDeserializer<'_, E> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:888:6 | 888 | impl<'de, 'a, E> IntoDeserializer<'de, E> for &'a [u8] | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 888 - impl<'de, 'a, E> IntoDeserializer<'de, E> for &'a [u8] 888 + impl<'a, E> IntoDeserializer<'_, E> for &'a [u8] | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:899:11 | 899 | impl<'de, 'a, E> Deserializer<'de> for BytesDeserializer<'a, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 899 - impl<'de, 'a, E> Deserializer<'de> for BytesDeserializer<'a, E> 899 + impl<'de, E> Deserializer<'de> for BytesDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'de, 'a --> serde/src/de/value.rs:919:6 | 919 | impl<'de, 'a, E> IntoDeserializer<'de, E> for BytesDeserializer<'a, E> | ^^^ ^^ ^^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 919 - impl<'de, 'a, E> IntoDeserializer<'de, E> for BytesDeserializer<'a, E> 919 + impl<E> IntoDeserializer<'_, E> for BytesDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:930:6 | 930 | impl<'a, E> Debug for BytesDeserializer<'a, E> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 930 - impl<'a, E> Debug for BytesDeserializer<'a, E> { 930 + impl<E> Debug for BytesDeserializer<'_, E> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:989:6 | 989 | impl<'de, E> Debug for BorrowedBytesDeserializer<'de, E> { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 989 - impl<'de, E> Debug for BorrowedBytesDeserializer<'de, E> { 989 + impl<E> Debug for BorrowedBytesDeserializer<'_, E> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:1238:6 | 1238 | impl<'de, I, E> MapDeserializer<'de, I, E> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 1238 - impl<'de, I, E> MapDeserializer<'de, I, E> 1238 + impl<I, E> MapDeserializer<'_, I, E> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:1255:6 | 1255 | impl<'de, I, E> MapDeserializer<'de, I, E> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 1255 - impl<'de, I, E> MapDeserializer<'de, I, E> 1255 + impl<I, E> MapDeserializer<'_, I, E> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:1278:6 | 1278 | impl<'de, I, E> MapDeserializer<'de, I, E> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 1278 - impl<'de, I, E> MapDeserializer<'de, I, E> 1278 + impl<I, E> MapDeserializer<'_, I, E> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:1439:6 | 1439 | impl<'de, I, E> Clone for MapDeserializer<'de, I, E> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 1439 - impl<'de, I, E> Clone for MapDeserializer<'de, I, E> 1439 + impl<I, E> Clone for MapDeserializer<'_, I, E> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:1456:6 | 1456 | impl<'de, I, E> Debug for MapDeserializer<'de, I, E> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 1456 - impl<'de, I, E> Debug for MapDeserializer<'de, I, E> 1456 + impl<I, E> Debug for MapDeserializer<'_, I, E> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:17:6 | 17 | impl<'de> Visitor<'de> for UnitVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 17 - impl<'de> Visitor<'de> for UnitVisitor { 17 + impl Visitor<'_> for UnitVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:56:6 | 56 | impl<'de> Visitor<'de> for BoolVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 56 - impl<'de> Visitor<'de> for BoolVisitor { 56 + impl Visitor<'_> for BoolVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:550:6 | 550 | impl<'de> Visitor<'de> for CharVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 550 - impl<'de> Visitor<'de> for CharVisitor { 550 + impl Visitor<'_> for CharVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:596:6 | 596 | impl<'de> Visitor<'de> for StringVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 596 - impl<'de> Visitor<'de> for StringVisitor { 596 + impl Visitor<'_> for StringVisitor { | warning: the following explicit lifetimes could be elided: 'a, 'de --> serde/src/de/impls.rs:642:6 | 642 | impl<'a, 'de> Visitor<'de> for StringInPlaceVisitor<'a> { | ^^ ^^^ ^^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 642 - impl<'a, 'de> Visitor<'de> for StringInPlaceVisitor<'a> { 642 + impl Visitor<'_> for StringInPlaceVisitor<'_> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:953:6 | 953 | impl<'de, T> Visitor<'de> for PhantomDataVisitor<T> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 953 - impl<'de, T> Visitor<'de> for PhantomDataVisitor<T> 953 + impl<T> Visitor<'_> for PhantomDataVisitor<T> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/impls.rs:1195:14 | 1195 | impl<'a, 'de, T> Visitor<'de> for VecInPlaceVisitor<'a, T> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 1195 - impl<'a, 'de, T> Visitor<'de> for VecInPlaceVisitor<'a, T> 1195 + impl<'de, T> Visitor<'de> for VecInPlaceVisitor<'_, T> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:1838:6 | 1838 | impl<'de> Visitor<'de> for PathBufVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 1838 - impl<'de> Visitor<'de> for PathBufVisitor { 1838 + impl Visitor<'_> for PathBufVisitor { | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/impls.rs:1991:11 | 1991 | impl<'de, 'a, T> Deserialize<'de> for Cow<'a, T> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 1991 - impl<'de, 'a, T> Deserialize<'de> for Cow<'a, T> 1991 + impl<'de, T> Deserialize<'de> for Cow<'_, T> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:2161:22 | 2161 | impl<'de> Visitor<'de> for FieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2161 - impl<'de> Visitor<'de> for FieldVisitor { 2161 + impl Visitor<'_> for FieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:2300:22 | 2300 | impl<'de> Visitor<'de> for FieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2300 - impl<'de> Visitor<'de> for FieldVisitor { 2300 + impl Visitor<'_> for FieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:2501:18 | 2501 | impl<'de> Visitor<'de> for FieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2501 - impl<'de> Visitor<'de> for FieldVisitor { 2501 + impl Visitor<'_> for FieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:2658:18 | 2658 | impl<'de> Visitor<'de> for FieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2658 - impl<'de> Visitor<'de> for FieldVisitor { 2658 + impl Visitor<'_> for FieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:2796:18 | 2796 | impl<'de> Visitor<'de> for FieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2796 - impl<'de> Visitor<'de> for FieldVisitor { 2796 + impl Visitor<'_> for FieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:2907:22 | 2907 | impl<'de> Visitor<'de> for FieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2907 - impl<'de> Visitor<'de> for FieldVisitor { 2907 + impl Visitor<'_> for FieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:3018:22 | 3018 | impl<'de> Visitor<'de> for FieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 3018 - impl<'de> Visitor<'de> for FieldVisitor { 3018 + impl Visitor<'_> for FieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:3166:6 | 3166 | impl<'de, T> Visitor<'de> for FromStrVisitor<T> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 3166 - impl<'de, T> Visitor<'de> for FromStrVisitor<T> 3166 + impl<T> Visitor<'_> for FromStrVisitor<T> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/mod.rs:397:6 | 397 | impl<'a> fmt::Display for Unexpected<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 397 - impl<'a> fmt::Display for Unexpected<'a> { 397 + impl fmt::Display for Unexpected<'_> { | warning: the following explicit lifetimes could be elided: 'f, 'a --> serde/src/de/mod.rs:2309:14 | 2309 | impl<'f, 'a> fmt::Write for LookForDecimalPoint<'f, 'a> { | ^^ ^^ ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2309 - impl<'f, 'a> fmt::Write for LookForDecimalPoint<'f, 'a> { 2309 + impl fmt::Write for LookForDecimalPoint<'_, '_> { | warning: the following explicit lifetimes could be elided: 'a --> serde/src/ser/fmt.rs:38:6 | 38 | impl<'a> Serializer for &mut fmt::Formatter<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 38 - impl<'a> Serializer for &mut fmt::Formatter<'a> { 38 + impl Serializer for &mut fmt::Formatter<'_> { | warning: the following explicit lifetimes could be elided: 'a --> serde/src/ser/impls.rs:62:6 | 62 | impl<'a> Serialize for fmt::Arguments<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 62 - impl<'a> Serialize for fmt::Arguments<'a> { 62 + impl Serialize for fmt::Arguments<'_> { | warning: the following explicit lifetimes could be elided: 'a --> serde/src/format.rs:20:6 | 20 | impl<'a> Write for Buf<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 20 - impl<'a> Write for Buf<'a> { 20 + impl Write for Buf<'_> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/private/de.rs:254:10 | 254 | impl<'de> Content<'de> { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 254 - impl<'de> Content<'de> { 254 + impl Content<'_> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/private/de.rs:333:10 | 333 | impl<'de> ContentVisitor<'de> { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 333 - impl<'de> ContentVisitor<'de> { 333 + impl ContentVisitor<'_> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/private/de.rs:553:10 | 553 | impl<'de> TagOrContentVisitor<'de> { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 553 - impl<'de> TagOrContentVisitor<'de> { 553 + impl TagOrContentVisitor<'_> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/private/de.rs:937:10 | 937 | impl<'de> Visitor<'de> for TagOrContentFieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 937 - impl<'de> Visitor<'de> for TagOrContentFieldVisitor { 937 + impl Visitor<'_> for TagOrContentFieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/private/de.rs:1014:10 | 1014 | impl<'de> Visitor<'de> for TagContentOtherFieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 1014 - impl<'de> Visitor<'de> for TagContentOtherFieldVisitor { 1014 + impl Visitor<'_> for TagContentOtherFieldVisitor { | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:1652:10 | 1652 | impl<'a, 'de, E> ContentRefDeserializer<'a, 'de, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 1652 - impl<'a, 'de, E> ContentRefDeserializer<'a, 'de, E> 1652 + impl<'de, E> ContentRefDeserializer<'_, 'de, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:1735:15 | 1735 | impl<'de, 'a, E> Deserializer<'de> for ContentRefDeserializer<'a, 'de, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 1735 - impl<'de, 'a, E> Deserializer<'de> for ContentRefDeserializer<'a, 'de, E> 1735 + impl<'de, E> Deserializer<'de> for ContentRefDeserializer<'_, 'de, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:2162:15 | 2162 | impl<'de, 'a, E> de::VariantAccess<'de> for VariantRefDeserializer<'a, 'de, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2162 - impl<'de, 'a, E> de::VariantAccess<'de> for VariantRefDeserializer<'a, 'de, E> 2162 + impl<'de, E> de::VariantAccess<'de> for VariantRefDeserializer<'_, 'de, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:2259:15 | 2259 | impl<'de, 'a, E> de::IntoDeserializer<'de, E> for ContentRefDeserializer<'a, 'de, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2259 - impl<'de, 'a, E> de::IntoDeserializer<'de, E> for ContentRefDeserializer<'a, 'de, E> 2259 + impl<'de, E> de::IntoDeserializer<'de, E> for ContentRefDeserializer<'_, 'de, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:2288:15 | 2288 | impl<'de, 'a> Visitor<'de> for InternallyTaggedUnitVisitor<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2288 - impl<'de, 'a> Visitor<'de> for InternallyTaggedUnitVisitor<'a> { 2288 + impl<'de> Visitor<'de> for InternallyTaggedUnitVisitor<'_> { | warning: the following explicit lifetimes could be elided: 'de, 'a --> serde/src/private/de.rs:2333:10 | 2333 | impl<'de, 'a> Visitor<'de> for UntaggedUnitVisitor<'a> { | ^^^ ^^ ^^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2333 - impl<'de, 'a> Visitor<'de> for UntaggedUnitVisitor<'a> { 2333 + impl Visitor<'_> for UntaggedUnitVisitor<'_> { | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:2396:11 | 2396 | impl<'de, 'a, E> Deserializer<'de> for StrDeserializer<'a, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2396 - impl<'de, 'a, E> Deserializer<'de> for StrDeserializer<'a, E> 2396 + impl<'de, E> Deserializer<'de> for StrDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'a, 'de --> serde/src/private/de.rs:2498:6 | 2498 | impl<'a, 'de, E> FlatMapDeserializer<'a, 'de, E> | ^^ ^^^ ^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2498 - impl<'a, 'de, E> FlatMapDeserializer<'a, 'de, E> 2498 + impl<E> FlatMapDeserializer<'_, '_, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:2522:6 | 2522 | impl<'a, 'de, E> Deserializer<'de> for FlatMapDeserializer<'a, 'de, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2522 - impl<'a, 'de, E> Deserializer<'de> for FlatMapDeserializer<'a, 'de, E> 2522 + impl<'de, E> Deserializer<'de> for FlatMapDeserializer<'_, 'de, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:2658:6 | 2658 | impl<'a, 'de, E> MapAccess<'de> for FlatMapAccess<'a, 'de, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2658 - impl<'a, 'de, E> MapAccess<'de> for FlatMapAccess<'a, 'de, E> 2658 + impl<'de, E> MapAccess<'de> for FlatMapAccess<'_, 'de, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:2702:6 | 2702 | impl<'a, 'de, E> MapAccess<'de> for FlatStructAccess<'a, 'de, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 2702 - impl<'a, 'de, E> MapAccess<'de> for FlatStructAccess<'a, 'de, E> 2702 + impl<'de, E> MapAccess<'de> for FlatStructAccess<'_, 'de, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/seed.rs:8:6 | 8 | impl<'a, 'de, T> DeserializeSeed<'de> for InPlaceSeed<'a, T> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 8 - impl<'a, 'de, T> DeserializeSeed<'de> for InPlaceSeed<'a, T> 8 + impl<'de, T> DeserializeSeed<'de> for InPlaceSeed<'_, T> | warning: the following explicit lifetimes could be elided: 'a --> serde_derive/src/internals/case.rs:124:6 | 124 | impl<'a> Display for ParseError<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names = note: `-W clippy::elidable-lifetime-names` implied by `-W clippy::pedantic` = help: to override `-W clippy::pedantic` add `#[allow(clippy::elidable_lifetime_names)]` help: elide the lifetimes | 124 - impl<'a> Display for ParseError<'a> { 124 + impl Display for ParseError<'_> { | warning: the following explicit lifetimes could be elided: 'a --> serde_derive/src/de.rs:3109:6 | 3109 | impl<'a> ToTokens for DeImplGenerics<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 3109 - impl<'a> ToTokens for DeImplGenerics<'a> { 3109 + impl ToTokens for DeImplGenerics<'_> { | warning: the following explicit lifetimes could be elided: 'a --> serde_derive/src/de.rs:3191:6 | 3191 | impl<'a> ToTokens for DeTypeGenerics<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names help: elide the lifetimes | 3191 - impl<'a> ToTokens for DeTypeGenerics<'a> { 3191 + impl ToTokens for DeTypeGenerics<'_> { | warning: the following explicit lifetimes could be elided: 'a --> test_suite/tests/test_serde_path.rs:16:10 | 16 | impl<'a> AssertNotSerdeDeserialize<'a> for Foo {} | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#elidable_lifetime_names = note: `-W clippy::elidable-lifetime-names` implied by `-W clippy::pedantic` = help: to override `-W clippy::pedantic` add `#[allow(clippy::elidable_lifetime_names)]` help: elide the lifetimes | 16 - impl<'a> AssertNotSerdeDeserialize<'a> for Foo {} 16 + impl AssertNotSerdeDeserialize<'_> for Foo {} | |
||
![]() |
6a630cf283
|
Also link to stable proc_macro | ||
![]() |
7bfd518dd4
|
Release 1.0.218 | ||
![]() |
2b44efb085
|
Point standard library links to stable | ||
![]() |
930401b0dd
|
Release 1.0.217 | ||
![]() |
ad8dd4148b
|
Release 1.0.216 | ||
![]() |
9497463718
|
Mark all generated trait impls as #[automatically_derived] | ||
![]() |
e9c399c822 |
Mark generated impl de::Visitor blocks as #[automatically_derived]
This hides the generated visitors and field visitors from code coverage. |
||
![]() |
8939af48fe
|
Release 1.0.215 | ||
![]() |
edd6fe954b
|
Revert "Add checks for conflicts for aliases"
This reverts commit 5f9fffa53e8a48d9e1f32b1735542207c42f3ead. |
||
![]() |
a20e9249c5
|
Revert "pacify clippy"
This reverts commit 951ca5ace0ca0abf9b44e0d6c76005fbd3b77c5c. |
||
![]() |
c59e876bb3
|
Produce a separate warning for every colliding name | ||
![]() |
373edcd055
|
Keep track of a span for alias strings | ||
![]() |
f0b5c4f857
|
Move MultiName to a new module | ||
![]() |
3035d4fa34
|
Rename Name -> MultiName | ||
![]() |
951ca5ace0
|
pacify clippy | ||
![]() |
adf05a5bf6
|
Merge pull request #2562 from Mingun/alias-check
Add checks for conflicts for aliases |
||
![]() |
418062165f
|
Release 1.0.214 | ||
![]() |
5f9fffa53e |
Add checks for conflicts for aliases
- Check that alias is not the same as name of other field (it still can be the name of owning field/variant) - Check that aliases are unique, i. e. two different fields does not use the same alias |
||
![]() |
58a8d22931
|
Release 1.0.213 | ||
![]() |
b60e4092ec
|
Hygiene for macro-generated newtype struct deserialization with 'with' attr | ||
![]() |
7ae1b5f8f3
|
Release 1.0.212 | ||
![]() |
1e36ef551d
|
Fix hygiene of macro-generated local variable accesses in serde(with) wrappers | ||
![]() |
1b8310d98a
|
Release 1.0.211 | ||
![]() |
09f6d9361d
|
Collect field ident and aliases into a struct | ||
![]() |
c6a5be7f6a
|
Rename variant_names_idents -> variant_idents_aliases | ||
![]() |
0a06af8d21
|
Rename field_names_idents -> field_idents_aliases | ||
![]() |
3393ad6760
|
Make most of prepare_enum_variant_enum independent of variant_names_idents item type | ||
![]() |
ab4f3f3111
|
Reduce scope of quote_spanned on SerializeWith wrapper | ||
![]() |
00460b8dee
|
Fix wording in comments from PR 2558 | ||
![]() |
991e344804
|
Raise required compiler for serde_derive to 1.61
This is the rust-version declared by recent versions of Syn. |
||
![]() |
6a7de26e5a
|
Ignore uninlined_format_args pedantic clippy lint
warning: variables can be used directly in the `format!` string --> serde_derive/src/internals/attr.rs:546:36 | 546 | meta.error(format_args!("unknown serde container attribute `{}`", path)) | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args = note: `-W clippy::uninlined-format-args` implied by `-W clippy::pedantic` = help: to override `-W clippy::pedantic` add `#[allow(clippy::uninlined_format_args)]` help: change this to | 546 - meta.error(format_args!("unknown serde container attribute `{}`", path)) 546 + meta.error(format_args!("unknown serde container attribute `{path}`")) | warning: variables can be used directly in the `format!` string --> serde_derive/src/internals/attr.rs:940:36 | 940 | meta.error(format_args!("unknown serde variant attribute `{}`", path)) | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 940 - meta.error(format_args!("unknown serde variant attribute `{}`", path)) 940 + meta.error(format_args!("unknown serde variant attribute `{path}`")) | warning: variables can be used directly in the `format!` string --> serde_derive/src/internals/attr.rs:1095:33 | 1095 | ... format!("field `{}` does not have lifetime {}", ident, lifetime); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 1095 - format!("field `{}` does not have lifetime {}", ident, lifetime); 1095 + format!("field `{ident}` does not have lifetime {lifetime}"); | warning: variables can be used directly in the `format!` string --> serde_derive/src/internals/attr.rs:1196:47 | 1196 | ... let msg = format!( | _________________________________^ 1197 | | ... "field `{}` does not have lifetime {}", 1198 | | ... ident, lifetime, 1199 | | ... ); | |_______________________^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args warning: variables can be used directly in the `format!` string --> serde_derive/src/internals/attr.rs:1222:36 | 1222 | meta.error(format_args!("unknown serde field attribute `{}`", path)) | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 1222 - meta.error(format_args!("unknown serde field attribute `{}`", path)) 1222 + meta.error(format_args!("unknown serde field attribute `{path}`")) | warning: variables can be used directly in the `format!` string --> serde_derive/src/internals/attr.rs:1415:39 | 1415 | return Err(meta.error(format_args!( | _______________________________________^ 1416 | | "malformed {0} attribute, expected `{0}(serialize = ..., deserialize = ...)`", 1417 | | attr_name, 1418 | | ))); | |_________________^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args warning: variables can be used directly in the `format!` string --> serde_derive/src/internals/attr.rs:1482:17 | 1482 | format!("unexpected suffix `{}` on string literal", suffix), | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 1482 - format!("unexpected suffix `{}` on string literal", suffix), 1482 + format!("unexpected suffix `{suffix}` on string literal"), | warning: variables can be used directly in the `format!` string --> serde_derive/src/internals/attr.rs:1489:13 | 1489 | / format!( 1490 | | "expected serde {} attribute to be a string: `{} = \"...\"`", 1491 | | attr_name, meta_item_name 1492 | | ), | |_____________^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args warning: variables can be used directly in the `format!` string --> serde_derive/src/internals/attr.rs:1604:21 | 1604 | format!("duplicate borrowed lifetime `{}`", lifetime), | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 1604 - format!("duplicate borrowed lifetime `{}`", lifetime), 1604 + format!("duplicate borrowed lifetime `{lifetime}`"), | warning: variables can be used directly in the `format!` string --> serde_derive/src/internals/attr.rs:1778:19 | 1778 | let msg = format!("field `{}` has no lifetimes to borrow", name); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 1778 - let msg = format!("field `{}` has no lifetimes to borrow", name); 1778 + let msg = format!("field `{name}` has no lifetimes to borrow"); | warning: variables can be used directly in the `format!` string --> serde_derive/src/internals/check.rs:41:29 | 41 | ... format!("field must have #[serde(default)] because previous field {} has #[serde(default)]", first), | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 41 - format!("field must have #[serde(default)] because previous field {} has #[serde(default)]", first), 41 + format!("field must have #[serde(default)] because previous field {first} has #[serde(default)]"), | warning: variables can be used directly in the `format!` string --> serde_derive/src/internals/check.rs:314:13 | 314 | format!("variant field name `{}` conflicts with internal tag", tag), | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 314 - format!("variant field name `{}` conflicts with internal tag", tag), 314 + format!("variant field name `{tag}` conflicts with internal tag"), | warning: variables can be used directly in the `format!` string --> serde_derive/src/internals/check.rs:361:13 | 361 | / format!( 362 | | "enum tags `{}` for type and content conflict with each other", 363 | | type_tag 364 | | ), | |_____________^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args warning: variables can be used directly in the `format!` string --> serde_derive/src/internals/check.rs:450:33 | 450 | Member::Named(ident) => format!("`{}`", ident), | ^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 450 - Member::Named(ident) => format!("`{}`", ident), 450 + Member::Named(ident) => format!("`{ident}`"), | warning: variables can be used directly in the `format!` string --> serde_derive/src/de.rs:697:9 | 697 | format!("{} with 1 element", expecting) | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 697 - format!("{} with 1 element", expecting) 697 + format!("{expecting} with 1 element") | warning: variables can be used directly in the `format!` string --> serde_derive/src/de.rs:699:9 | 699 | format!("{} with {} elements", expecting, deserialized_count) | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 699 - format!("{} with {} elements", expecting, deserialized_count) 699 + format!("{expecting} with {deserialized_count} elements") | warning: variables can be used directly in the `format!` string --> serde_derive/src/de.rs:1442:21 | 1442 | let expecting = format!("adjacently tagged enum {}", rust_name); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 1442 - let expecting = format!("adjacently tagged enum {}", rust_name); 1442 + let expecting = format!("adjacently tagged enum {rust_name}"); | warning: variables can be used directly in the `format!` string --> serde_derive/src/de.rs:2842:17 | 2842 | Ident::new(&format!("__field{}", i), Span::call_site()) | ^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 2842 - Ident::new(&format!("__field{}", i), Span::call_site()) 2842 + Ident::new(&format!("__field{i}"), Span::call_site()) | warning: variables can be used directly in the `format!` string --> serde_derive/src/ser.rs:457:42 | 457 | .map(|i| Ident::new(&format!("__field{}", i), Span::call_site())); | ^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 457 - .map(|i| Ident::new(&format!("__field{}", i), Span::call_site())); 457 + .map(|i| Ident::new(&format!("__field{i}"), Span::call_site())); | warning: variables can be used directly in the `format!` string --> serde_derive/src/ser.rs:714:48 | 714 | .map(|i| Member::Named(Ident::new(&format!("__field{}", i), Span::call_site()))) | ^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 714 - .map(|i| Member::Named(Ident::new(&format!("__field{}", i), Span::call_site()))) 714 + .map(|i| Member::Named(Ident::new(&format!("__field{i}"), Span::call_site()))) | warning: variables can be used directly in the `format!` string --> serde_derive/src/ser.rs:832:46 | 832 | let field_expr = Ident::new(&format!("__field{}", i), Span::call_site()); | ^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 832 - let field_expr = Ident::new(&format!("__field{}", i), Span::call_site()); 832 + let field_expr = Ident::new(&format!("__field{i}"), Span::call_site()); | warning: variables can be used directly in the `format!` string --> serde_derive/src/ser.rs:1062:38 | 1062 | let id = Ident::new(&format!("__field{}", i), Span::call_site()); | ^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args help: change this to | 1062 - let id = Ident::new(&format!("__field{}", i), Span::call_site()); 1062 + let id = Ident::new(&format!("__field{i}"), Span::call_site()); | |
||
![]() |
a8cbc9184e
|
Ignore needless_lifetimes clippy lint in generated code | ||
![]() |
3415619bfd
|
Merge pull request #2566 from Mingun/variant-aliases
Show variant aliases in error message |
||
![]() |
04bb76bc00
|
Merge pull request #2558 from Mingun/correct-span
Improve error reporting about mismatched signature in `with` and `default` attributes |
||
![]() |
8b0f482666
|
Update for precise capture bounds
warning: some variants are not matched explicitly --> serde_derive/src/internals/receiver.rs:209:15 | 209 | match bound { | ^^^^^ pattern `&mut TypeParamBound::PreciseCapture(_)` not covered | = help: ensure that all variants are matched explicitly by adding the suggested match arms = note: the matched value is of type `&mut TypeParamBound` and the `non_exhaustive_omitted_patterns` attribute was found note: the lint level is defined here --> serde_derive/src/internals/receiver.rs:210:53 | 210 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ warning: some variants are not matched explicitly --> serde_derive/src/bound.rs:227:19 | 227 | match bound { | ^^^^^ pattern `&TypeParamBound::PreciseCapture(_)` not covered | = help: ensure that all variants are matched explicitly by adding the suggested match arms = note: the matched value is of type `&TypeParamBound` and the `non_exhaustive_omitted_patterns` attribute was found note: the lint level is defined here --> serde_derive/src/bound.rs:228:57 | 228 | #![cfg_attr(all(test, exhaustive), deny(non_exhaustive_omitted_patterns))] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
||
![]() |
4b3178b053
|
Ignore needless_lifetimes clippy lint
warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:124:6 | 124 | impl<'de, E> IntoDeserializer<'de, E> for () | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes = note: `-W clippy::needless-lifetimes` implied by `-W clippy::all` = help: to override `-W clippy::all` add `#[allow(clippy::needless_lifetimes)]` help: elide the lifetimes | 124 - impl<'de, E> IntoDeserializer<'de, E> for () 124 + impl<E> IntoDeserializer<'_, E> for () | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:196:6 | 196 | impl<'de, E> IntoDeserializer<'de, E> for ! | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 196 - impl<'de, E> IntoDeserializer<'de, E> for ! 196 + impl<E> IntoDeserializer<'_, E> for ! | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:317:6 | 317 | impl<'de, E> IntoDeserializer<'de, E> for u32 | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 317 - impl<'de, E> IntoDeserializer<'de, E> for u32 317 + impl<E> IntoDeserializer<'_, E> for u32 | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:406:6 | 406 | impl<'de, 'a, E> IntoDeserializer<'de, E> for &'a str | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 406 - impl<'de, 'a, E> IntoDeserializer<'de, E> for &'a str 406 + impl<'a, E> IntoDeserializer<'_, E> for &'a str | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:427:11 | 427 | impl<'de, 'a, E> de::Deserializer<'de> for StrDeserializer<'a, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 427 - impl<'de, 'a, E> de::Deserializer<'de> for StrDeserializer<'a, E> 427 + impl<'de, E> de::Deserializer<'de> for StrDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:461:11 | 461 | impl<'de, 'a, E> de::EnumAccess<'de> for StrDeserializer<'a, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 461 - impl<'de, 'a, E> de::EnumAccess<'de> for StrDeserializer<'a, E> 461 + impl<'de, E> de::EnumAccess<'de> for StrDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:476:6 | 476 | impl<'a, E> Debug for StrDeserializer<'a, E> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 476 - impl<'a, E> Debug for StrDeserializer<'a, E> { 476 + impl<E> Debug for StrDeserializer<'_, E> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:555:6 | 555 | impl<'de, E> Debug for BorrowedStrDeserializer<'de, E> { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 555 - impl<'de, E> Debug for BorrowedStrDeserializer<'de, E> { 555 + impl<E> Debug for BorrowedStrDeserializer<'_, E> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:586:6 | 586 | impl<'de, E> IntoDeserializer<'de, E> for String | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 586 - impl<'de, E> IntoDeserializer<'de, E> for String 586 + impl<E> IntoDeserializer<'_, E> for String | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:680:6 | 680 | impl<'a, E> Clone for CowStrDeserializer<'a, E> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 680 - impl<'a, E> Clone for CowStrDeserializer<'a, E> { 680 + impl<E> Clone for CowStrDeserializer<'_, E> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:691:6 | 691 | impl<'de, 'a, E> IntoDeserializer<'de, E> for Cow<'a, str> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 691 - impl<'de, 'a, E> IntoDeserializer<'de, E> for Cow<'a, str> 691 + impl<'a, E> IntoDeserializer<'_, E> for Cow<'a, str> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:714:11 | 714 | impl<'de, 'a, E> de::Deserializer<'de> for CowStrDeserializer<'a, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 714 - impl<'de, 'a, E> de::Deserializer<'de> for CowStrDeserializer<'a, E> 714 + impl<'de, E> de::Deserializer<'de> for CowStrDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:752:11 | 752 | impl<'de, 'a, E> de::EnumAccess<'de> for CowStrDeserializer<'a, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 752 - impl<'de, 'a, E> de::EnumAccess<'de> for CowStrDeserializer<'a, E> 752 + impl<'de, E> de::EnumAccess<'de> for CowStrDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:768:6 | 768 | impl<'a, E> Debug for CowStrDeserializer<'a, E> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 768 - impl<'a, E> Debug for CowStrDeserializer<'a, E> { 768 + impl<E> Debug for CowStrDeserializer<'_, E> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:797:6 | 797 | impl<'de, 'a, E> IntoDeserializer<'de, E> for &'a [u8] | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 797 - impl<'de, 'a, E> IntoDeserializer<'de, E> for &'a [u8] 797 + impl<'a, E> IntoDeserializer<'_, E> for &'a [u8] | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:808:11 | 808 | impl<'de, 'a, E> Deserializer<'de> for BytesDeserializer<'a, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 808 - impl<'de, 'a, E> Deserializer<'de> for BytesDeserializer<'a, E> 808 + impl<'de, E> Deserializer<'de> for BytesDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/value.rs:828:6 | 828 | impl<'a, E> Debug for BytesDeserializer<'a, E> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 828 - impl<'a, E> Debug for BytesDeserializer<'a, E> { 828 + impl<E> Debug for BytesDeserializer<'_, E> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:876:6 | 876 | impl<'de, E> Debug for BorrowedBytesDeserializer<'de, E> { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 876 - impl<'de, E> Debug for BorrowedBytesDeserializer<'de, E> { 876 + impl<E> Debug for BorrowedBytesDeserializer<'_, E> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:1101:6 | 1101 | impl<'de, I, E> MapDeserializer<'de, I, E> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 1101 - impl<'de, I, E> MapDeserializer<'de, I, E> 1101 + impl<I, E> MapDeserializer<'_, I, E> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:1118:6 | 1118 | impl<'de, I, E> MapDeserializer<'de, I, E> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 1118 - impl<'de, I, E> MapDeserializer<'de, I, E> 1118 + impl<I, E> MapDeserializer<'_, I, E> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:1141:6 | 1141 | impl<'de, I, E> MapDeserializer<'de, I, E> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 1141 - impl<'de, I, E> MapDeserializer<'de, I, E> 1141 + impl<I, E> MapDeserializer<'_, I, E> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:1287:6 | 1287 | impl<'de, I, E> Clone for MapDeserializer<'de, I, E> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 1287 - impl<'de, I, E> Clone for MapDeserializer<'de, I, E> 1287 + impl<I, E> Clone for MapDeserializer<'_, I, E> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/value.rs:1304:6 | 1304 | impl<'de, I, E> Debug for MapDeserializer<'de, I, E> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 1304 - impl<'de, I, E> Debug for MapDeserializer<'de, I, E> 1304 + impl<I, E> Debug for MapDeserializer<'_, I, E> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:17:6 | 17 | impl<'de> Visitor<'de> for UnitVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 17 - impl<'de> Visitor<'de> for UnitVisitor { 17 + impl Visitor<'_> for UnitVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:56:6 | 56 | impl<'de> Visitor<'de> for BoolVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 56 - impl<'de> Visitor<'de> for BoolVisitor { 56 + impl Visitor<'_> for BoolVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:550:6 | 550 | impl<'de> Visitor<'de> for CharVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 550 - impl<'de> Visitor<'de> for CharVisitor { 550 + impl Visitor<'_> for CharVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:596:6 | 596 | impl<'de> Visitor<'de> for StringVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 596 - impl<'de> Visitor<'de> for StringVisitor { 596 + impl Visitor<'_> for StringVisitor { | warning: the following explicit lifetimes could be elided: 'de, 'a --> serde/src/de/impls.rs:642:6 | 642 | impl<'a, 'de> Visitor<'de> for StringInPlaceVisitor<'a> { | ^^ ^^^ ^^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 642 - impl<'a, 'de> Visitor<'de> for StringInPlaceVisitor<'a> { 642 + impl Visitor<'_> for StringInPlaceVisitor<'_> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:953:6 | 953 | impl<'de, T> Visitor<'de> for PhantomDataVisitor<T> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 953 - impl<'de, T> Visitor<'de> for PhantomDataVisitor<T> 953 + impl<T> Visitor<'_> for PhantomDataVisitor<T> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/impls.rs:1195:14 | 1195 | impl<'a, 'de, T> Visitor<'de> for VecInPlaceVisitor<'a, T> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 1195 - impl<'a, 'de, T> Visitor<'de> for VecInPlaceVisitor<'a, T> 1195 + impl<'de, T> Visitor<'de> for VecInPlaceVisitor<'_, T> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:1838:6 | 1838 | impl<'de> Visitor<'de> for PathBufVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 1838 - impl<'de> Visitor<'de> for PathBufVisitor { 1838 + impl Visitor<'_> for PathBufVisitor { | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/impls.rs:1991:11 | 1991 | impl<'de, 'a, T> Deserialize<'de> for Cow<'a, T> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 1991 - impl<'de, 'a, T> Deserialize<'de> for Cow<'a, T> 1991 + impl<'de, T> Deserialize<'de> for Cow<'_, T> | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:2161:22 | 2161 | impl<'de> Visitor<'de> for FieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2161 - impl<'de> Visitor<'de> for FieldVisitor { 2161 + impl Visitor<'_> for FieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:2300:22 | 2300 | impl<'de> Visitor<'de> for FieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2300 - impl<'de> Visitor<'de> for FieldVisitor { 2300 + impl Visitor<'_> for FieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:2501:18 | 2501 | impl<'de> Visitor<'de> for FieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2501 - impl<'de> Visitor<'de> for FieldVisitor { 2501 + impl Visitor<'_> for FieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:2658:18 | 2658 | impl<'de> Visitor<'de> for FieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2658 - impl<'de> Visitor<'de> for FieldVisitor { 2658 + impl Visitor<'_> for FieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:2796:18 | 2796 | impl<'de> Visitor<'de> for FieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2796 - impl<'de> Visitor<'de> for FieldVisitor { 2796 + impl Visitor<'_> for FieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:2907:22 | 2907 | impl<'de> Visitor<'de> for FieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2907 - impl<'de> Visitor<'de> for FieldVisitor { 2907 + impl Visitor<'_> for FieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:3018:22 | 3018 | impl<'de> Visitor<'de> for FieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 3018 - impl<'de> Visitor<'de> for FieldVisitor { 3018 + impl Visitor<'_> for FieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/de/impls.rs:3166:6 | 3166 | impl<'de, T> Visitor<'de> for FromStrVisitor<T> | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 3166 - impl<'de, T> Visitor<'de> for FromStrVisitor<T> 3166 + impl<T> Visitor<'_> for FromStrVisitor<T> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/mod.rs:397:6 | 397 | impl<'a> fmt::Display for Unexpected<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 397 - impl<'a> fmt::Display for Unexpected<'a> { 397 + impl fmt::Display for Unexpected<'_> { | warning: the following explicit lifetimes could be elided: 'f, 'a --> serde/src/de/mod.rs:2309:14 | 2309 | impl<'f, 'a> fmt::Write for LookForDecimalPoint<'f, 'a> { | ^^ ^^ ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2309 - impl<'f, 'a> fmt::Write for LookForDecimalPoint<'f, 'a> { 2309 + impl fmt::Write for LookForDecimalPoint<'_, '_> { | warning: the following explicit lifetimes could be elided: 'a --> serde/src/ser/fmt.rs:38:6 | 38 | impl<'a> Serializer for &mut fmt::Formatter<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 38 - impl<'a> Serializer for &mut fmt::Formatter<'a> { 38 + impl Serializer for &mut fmt::Formatter<'_> { | warning: the following explicit lifetimes could be elided: 'a --> serde/src/ser/impls.rs:62:6 | 62 | impl<'a> Serialize for fmt::Arguments<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 62 - impl<'a> Serialize for fmt::Arguments<'a> { 62 + impl Serialize for fmt::Arguments<'_> { | warning: the following explicit lifetimes could be elided: 'a --> serde/src/format.rs:20:6 | 20 | impl<'a> Write for Buf<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 20 - impl<'a> Write for Buf<'a> { 20 + impl Write for Buf<'_> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/private/de.rs:254:10 | 254 | impl<'de> Content<'de> { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 254 - impl<'de> Content<'de> { 254 + impl Content<'_> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/private/de.rs:333:10 | 333 | impl<'de> ContentVisitor<'de> { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 333 - impl<'de> ContentVisitor<'de> { 333 + impl ContentVisitor<'_> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/private/de.rs:553:10 | 553 | impl<'de> TagOrContentVisitor<'de> { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 553 - impl<'de> TagOrContentVisitor<'de> { 553 + impl TagOrContentVisitor<'_> { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/private/de.rs:937:10 | 937 | impl<'de> Visitor<'de> for TagOrContentFieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 937 - impl<'de> Visitor<'de> for TagOrContentFieldVisitor { 937 + impl Visitor<'_> for TagOrContentFieldVisitor { | warning: the following explicit lifetimes could be elided: 'de --> serde/src/private/de.rs:1014:10 | 1014 | impl<'de> Visitor<'de> for TagContentOtherFieldVisitor { | ^^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 1014 - impl<'de> Visitor<'de> for TagContentOtherFieldVisitor { 1014 + impl Visitor<'_> for TagContentOtherFieldVisitor { | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:1652:10 | 1652 | impl<'a, 'de, E> ContentRefDeserializer<'a, 'de, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 1652 - impl<'a, 'de, E> ContentRefDeserializer<'a, 'de, E> 1652 + impl<'de, E> ContentRefDeserializer<'_, 'de, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:1735:15 | 1735 | impl<'de, 'a, E> Deserializer<'de> for ContentRefDeserializer<'a, 'de, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 1735 - impl<'de, 'a, E> Deserializer<'de> for ContentRefDeserializer<'a, 'de, E> 1735 + impl<'de, E> Deserializer<'de> for ContentRefDeserializer<'_, 'de, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:2162:15 | 2162 | impl<'de, 'a, E> de::VariantAccess<'de> for VariantRefDeserializer<'a, 'de, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2162 - impl<'de, 'a, E> de::VariantAccess<'de> for VariantRefDeserializer<'a, 'de, E> 2162 + impl<'de, E> de::VariantAccess<'de> for VariantRefDeserializer<'_, 'de, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:2259:15 | 2259 | impl<'de, 'a, E> de::IntoDeserializer<'de, E> for ContentRefDeserializer<'a, 'de, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2259 - impl<'de, 'a, E> de::IntoDeserializer<'de, E> for ContentRefDeserializer<'a, 'de, E> 2259 + impl<'de, E> de::IntoDeserializer<'de, E> for ContentRefDeserializer<'_, 'de, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:2288:15 | 2288 | impl<'de, 'a> Visitor<'de> for InternallyTaggedUnitVisitor<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2288 - impl<'de, 'a> Visitor<'de> for InternallyTaggedUnitVisitor<'a> { 2288 + impl<'de> Visitor<'de> for InternallyTaggedUnitVisitor<'_> { | warning: the following explicit lifetimes could be elided: 'a, 'de --> serde/src/private/de.rs:2333:10 | 2333 | impl<'de, 'a> Visitor<'de> for UntaggedUnitVisitor<'a> { | ^^^ ^^ ^^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2333 - impl<'de, 'a> Visitor<'de> for UntaggedUnitVisitor<'a> { 2333 + impl Visitor<'_> for UntaggedUnitVisitor<'_> { | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:2396:11 | 2396 | impl<'de, 'a, E> Deserializer<'de> for StrDeserializer<'a, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2396 - impl<'de, 'a, E> Deserializer<'de> for StrDeserializer<'a, E> 2396 + impl<'de, E> Deserializer<'de> for StrDeserializer<'_, E> | warning: the following explicit lifetimes could be elided: 'a, 'de --> serde/src/private/de.rs:2498:6 | 2498 | impl<'a, 'de, E> FlatMapDeserializer<'a, 'de, E> | ^^ ^^^ ^^ ^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2498 - impl<'a, 'de, E> FlatMapDeserializer<'a, 'de, E> 2498 + impl<E> FlatMapDeserializer<'_, '_, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:2522:6 | 2522 | impl<'a, 'de, E> Deserializer<'de> for FlatMapDeserializer<'a, 'de, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2522 - impl<'a, 'de, E> Deserializer<'de> for FlatMapDeserializer<'a, 'de, E> 2522 + impl<'de, E> Deserializer<'de> for FlatMapDeserializer<'_, 'de, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:2658:6 | 2658 | impl<'a, 'de, E> MapAccess<'de> for FlatMapAccess<'a, 'de, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2658 - impl<'a, 'de, E> MapAccess<'de> for FlatMapAccess<'a, 'de, E> 2658 + impl<'de, E> MapAccess<'de> for FlatMapAccess<'_, 'de, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/private/de.rs:2702:6 | 2702 | impl<'a, 'de, E> MapAccess<'de> for FlatStructAccess<'a, 'de, E> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 2702 - impl<'a, 'de, E> MapAccess<'de> for FlatStructAccess<'a, 'de, E> 2702 + impl<'de, E> MapAccess<'de> for FlatStructAccess<'_, 'de, E> | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/seed.rs:8:6 | 8 | impl<'a, 'de, T> DeserializeSeed<'de> for InPlaceSeed<'a, T> | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 8 - impl<'a, 'de, T> DeserializeSeed<'de> for InPlaceSeed<'a, T> 8 + impl<'de, T> DeserializeSeed<'de> for InPlaceSeed<'_, T> | warning: the following explicit lifetimes could be elided: 'a --> serde_derive/src/internals/case.rs:124:6 | 124 | impl<'a> Display for ParseError<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes = note: `-W clippy::needless-lifetimes` implied by `-W clippy::all` = help: to override `-W clippy::all` add `#[allow(clippy::needless_lifetimes)]` help: elide the lifetimes | 124 - impl<'a> Display for ParseError<'a> { 124 + impl Display for ParseError<'_> { | warning: the following explicit lifetimes could be elided: 'a --> serde_derive/src/de.rs:3042:6 | 3042 | impl<'a> ToTokens for DeImplGenerics<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 3042 - impl<'a> ToTokens for DeImplGenerics<'a> { 3042 + impl ToTokens for DeImplGenerics<'_> { | warning: the following explicit lifetimes could be elided: 'a --> serde_derive/src/de.rs:3124:6 | 3124 | impl<'a> ToTokens for DeTypeGenerics<'a> { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 3124 - impl<'a> ToTokens for DeTypeGenerics<'a> { 3124 + impl ToTokens for DeTypeGenerics<'_> { | warning: the following explicit lifetimes could be elided: 'a --> test_suite/tests/test_serde_path.rs:15:10 | 15 | impl<'a> AssertNotSerdeDeserialize<'a> for Foo {} | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes = note: `-W clippy::needless-lifetimes` implied by `-W clippy::all` = help: to override `-W clippy::all` add `#[allow(clippy::needless_lifetimes)]` help: elide the lifetimes | 15 - impl<'a> AssertNotSerdeDeserialize<'a> for Foo {} 15 + impl AssertNotSerdeDeserialize<'_> for Foo {} | |
||
![]() |
8e1ae68569
|
Resolve some needless_lifetimes clippy lints
warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/mod.rs:489:6 | 489 | impl<'a> Expected for &'a str { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 489 - impl<'a> Expected for &'a str { 489 + impl Expected for &str { | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/mod.rs:495:6 | 495 | impl<'a> Display for Expected + 'a { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 495 - impl<'a> Display for Expected + 'a { 495 + impl Display for Expected + '_ { | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/mod.rs:1744:11 | 1744 | impl<'de, 'a, A> SeqAccess<'de> for &'a mut A | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 1744 - impl<'de, 'a, A> SeqAccess<'de> for &'a mut A 1744 + impl<'de, A> SeqAccess<'de> for &mut A | warning: the following explicit lifetimes could be elided: 'a --> serde/src/de/mod.rs:1897:11 | 1897 | impl<'de, 'a, A> MapAccess<'de> for &'a mut A | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 1897 - impl<'de, 'a, A> MapAccess<'de> for &'a mut A 1897 + impl<'de, A> MapAccess<'de> for &mut A | warning: the following explicit lifetimes could be elided: 'a, 'b --> serde/src/ser/fmt.rs:38:6 | 38 | impl<'a, 'b> Serializer for &'a mut fmt::Formatter<'b> { | ^^ ^^ ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 38 - impl<'a, 'b> Serializer for &'a mut fmt::Formatter<'b> { 38 + impl Serializer for &mut fmt::Formatter<'_> { | warning: the following explicit lifetimes could be elided: 'a --> serde_derive/src/internals/symbol.rs:49:6 | 49 | impl<'a> PartialEq<Symbol> for &'a Ident { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 49 - impl<'a> PartialEq<Symbol> for &'a Ident { 49 + impl PartialEq<Symbol> for &Ident { | warning: the following explicit lifetimes could be elided: 'a --> serde_derive/src/internals/symbol.rs:61:6 | 61 | impl<'a> PartialEq<Symbol> for &'a Path { | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 61 - impl<'a> PartialEq<Symbol> for &'a Path { 61 + impl PartialEq<Symbol> for &Path { | |