From ca1bbdaddee846d47af1ed95cbfc22615b30cb67 Mon Sep 17 00:00:00 2001 From: Jonas Bushart Date: Mon, 7 Jun 2021 21:09:49 +0200 Subject: [PATCH] Bump Versions serde_with -> 1.9.2 serde_with_macros -> 1.4.2 --- CHANGELOG.md | 7 +++++++ Cargo.toml | 4 ++-- README.md | 18 +++++++++--------- serde_with_macros/CHANGELOG.md | 4 +++- serde_with_macros/Cargo.toml | 2 +- serde_with_macros/src/lib.rs | 10 +++++----- src/lib.rs | 30 +++++++++++++++--------------- 7 files changed, 42 insertions(+), 33 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 07ee831c..a6895f72 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,13 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ## [Unreleased] +## [1.9.2] - 2021-06-07 + +### Fixed + +* Suppress clippy warnings, which can occur while using `serde_conv` (#320) + Thanks to @mkroening for reporting and fixing the issue. + ## [1.9.1] - 2021-05-15 ### Changed diff --git a/Cargo.toml b/Cargo.toml index 6ca84ed0..329be7cc 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -11,7 +11,7 @@ authors = [ "Marcin Kaźmierczak", ] name = "serde_with" -version = "1.9.1" +version = "1.9.2" categories = ["encoding"] description = "Custom de/serialization functions for Rust's serde" @@ -43,7 +43,7 @@ hex = {version = "0.4.2", optional = true} rustversion = "1.0.0" serde = {version = "1.0.122", features = ["derive"]} serde_json = {version = "1.0.1", optional = true} -serde_with_macros = {path = "./serde_with_macros", version = "1.4.1", optional = true} +serde_with_macros = {path = "./serde_with_macros", version = "1.4.2", optional = true} [dev-dependencies] expect-test = "1.0.0" diff --git a/README.md b/README.md index 347ae6c8..bce172b0 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ Add this to your `Cargo.toml`: ```toml [dependencies.serde_with] -version = "1.9.1" +version = "1.9.2" features = [ "..." ] ``` @@ -124,15 +124,15 @@ Foo { } ``` -[`DisplayFromStr`]: https://docs.rs/serde_with/1.9.1/serde_with/struct.DisplayFromStr.html -[`with_prefix!`]: https://docs.rs/serde_with/1.9.1/serde_with/macro.with_prefix.html -[display_fromstr]: https://docs.rs/serde_with/1.9.1/serde_with/rust/display_fromstr/index.html -[feature flags]: https://docs.rs/serde_with/1.9.1/serde_with/guide/feature_flags/index.html -[skip_serializing_none]: https://docs.rs/serde_with/1.9.1/serde_with/attr.skip_serializing_none.html -[StringWithSeparator]: https://docs.rs/serde_with/1.9.1/serde_with/rust/struct.StringWithSeparator.html -[user guide]: https://docs.rs/serde_with/1.9.1/serde_with/guide/index.html +[`DisplayFromStr`]: https://docs.rs/serde_with/1.9.2/serde_with/struct.DisplayFromStr.html +[`with_prefix!`]: https://docs.rs/serde_with/1.9.2/serde_with/macro.with_prefix.html +[display_fromstr]: https://docs.rs/serde_with/1.9.2/serde_with/rust/display_fromstr/index.html +[feature flags]: https://docs.rs/serde_with/1.9.2/serde_with/guide/feature_flags/index.html +[skip_serializing_none]: https://docs.rs/serde_with/1.9.2/serde_with/attr.skip_serializing_none.html +[StringWithSeparator]: https://docs.rs/serde_with/1.9.2/serde_with/rust/struct.StringWithSeparator.html +[user guide]: https://docs.rs/serde_with/1.9.2/serde_with/guide/index.html [with-annotation]: https://serde.rs/field-attrs.html#with -[as-annotation]: https://docs.rs/serde_with/1.9.1/serde_with/guide/serde_as/index.html +[as-annotation]: https://docs.rs/serde_with/1.9.2/serde_with/guide/serde_as/index.html ## License diff --git a/serde_with_macros/CHANGELOG.md b/serde_with_macros/CHANGELOG.md index e08bc631..92a4efc1 100644 --- a/serde_with_macros/CHANGELOG.md +++ b/serde_with_macros/CHANGELOG.md @@ -7,6 +7,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ## Unreleased +## [1.4.2] - 2021-06-07 + ### Fixed * Describe how the `serde_as` macro works on a high level. @@ -14,7 +16,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. Properly name all types and traits required for the expanded code to work. The tests were improved to be better able to catch such problems. -## [1.4.1] - 2021-02-16 +## [1.4.2] - 2021-02-16 ### Fixed diff --git a/serde_with_macros/Cargo.toml b/serde_with_macros/Cargo.toml index a2464d4b..60b6508d 100644 --- a/serde_with_macros/Cargo.toml +++ b/serde_with_macros/Cargo.toml @@ -1,7 +1,7 @@ [package] authors = ["Jonas Bushart"] name = "serde_with_macros" -version = "1.4.1" +version = "1.4.2" categories = ["encoding"] description = "proc-macro library for serde_with" diff --git a/serde_with_macros/src/lib.rs b/serde_with_macros/src/lib.rs index 5ced4f45..6da80c52 100644 --- a/serde_with_macros/src/lib.rs +++ b/serde_with_macros/src/lib.rs @@ -26,7 +26,7 @@ #![doc(test(attr(warn(rust_2018_idioms))))] // Not needed for 2018 edition and conflicts with `rust_2018_idioms` #![doc(test(no_crate_inject))] -#![doc(html_root_url = "https://docs.rs/serde_with_macros/1.4.1")] +#![doc(html_root_url = "https://docs.rs/serde_with_macros/1.4.2")] // Necessary to silence the warning about clippy::unknown_clippy_lints on nightly #![allow(renamed_and_removed_lints)] // Necessary for nightly clippy lints @@ -479,8 +479,8 @@ fn field_has_attribute(field: &Field, namespace: &str, name: &str) -> bool { /// } /// ``` /// -/// [`serde_as`]: https://docs.rs/serde_with/1.9.1/serde_with/guide/index.html -/// [re-exporting `serde_as`]: https://docs.rs/serde_with/1.9.1/serde_with/guide/serde_as/index.html#re-exporting-serde_as +/// [`serde_as`]: https://docs.rs/serde_with/1.9.2/serde_with/guide/index.html +/// [re-exporting `serde_as`]: https://docs.rs/serde_with/1.9.2/serde_with/guide/serde_as/index.html#re-exporting-serde_as #[proc_macro_attribute] pub fn serde_as(args: TokenStream, input: TokenStream) -> TokenStream { #[derive(FromMeta, Debug)] @@ -783,7 +783,7 @@ fn replace_infer_type_with_type(to_replace: Type, replacement: &Type) -> Type { /// [`Display`]: std::fmt::Display /// [`FromStr`]: std::str::FromStr /// [cargo-toml-rename]: https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#renaming-dependencies-in-cargotoml -/// [serde-as-crate]: https://docs.rs/serde_with/1.9.1/serde_with/guide/serde_as/index.html#re-exporting-serde_as +/// [serde-as-crate]: https://docs.rs/serde_with/1.9.2/serde_with/guide/serde_as/index.html#re-exporting-serde_as /// [serde-crate]: https://serde.rs/container-attrs.html#crate #[proc_macro_derive(DeserializeFromStr, attributes(serde_with))] pub fn derive_deserialize_fromstr(item: TokenStream) -> TokenStream { @@ -893,7 +893,7 @@ fn deserialize_fromstr(input: DeriveInput, serde_with_crate_path: Path) -> Token /// [`Display`]: std::fmt::Display /// [`FromStr`]: std::str::FromStr /// [cargo-toml-rename]: https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#renaming-dependencies-in-cargotoml -/// [serde-as-crate]: https://docs.rs/serde_with/1.9.1/serde_with/guide/serde_as/index.html#re-exporting-serde_as +/// [serde-as-crate]: https://docs.rs/serde_with/1.9.2/serde_with/guide/serde_as/index.html#re-exporting-serde_as /// [serde-crate]: https://serde.rs/container-attrs.html#crate #[proc_macro_derive(SerializeDisplay, attributes(serde_with))] pub fn derive_serialize_display(item: TokenStream) -> TokenStream { diff --git a/src/lib.rs b/src/lib.rs index 001769ab..1b65832d 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -25,7 +25,7 @@ #![doc(test(attr(warn(rust_2018_idioms))))] // Not needed for 2018 edition and conflicts with `rust_2018_idioms` #![doc(test(no_crate_inject))] -#![doc(html_root_url = "https://docs.rs/serde_with/1.9.1")] +#![doc(html_root_url = "https://docs.rs/serde_with/1.9.2")] // Necessary to silence the warning about clippy::unknown_clippy_lints on nightly #![allow(renamed_and_removed_lints)] // Rust 1.45: introduction of `strip_prefix` used by clippy::manual_strip @@ -61,7 +61,7 @@ //! //! ```toml //! [dependencies.serde_with] -//! version = "1.9.1" +//! version = "1.9.2" //! features = [ "..." ] //! ``` //! @@ -200,15 +200,15 @@ //! # } //! ``` //! -//! [`DisplayFromStr`]: https://docs.rs/serde_with/1.9.1/serde_with/struct.DisplayFromStr.html -//! [`with_prefix!`]: https://docs.rs/serde_with/1.9.1/serde_with/macro.with_prefix.html -//! [display_fromstr]: https://docs.rs/serde_with/1.9.1/serde_with/rust/display_fromstr/index.html -//! [feature flags]: https://docs.rs/serde_with/1.9.1/serde_with/guide/feature_flags/index.html -//! [skip_serializing_none]: https://docs.rs/serde_with/1.9.1/serde_with/attr.skip_serializing_none.html -//! [StringWithSeparator]: https://docs.rs/serde_with/1.9.1/serde_with/rust/struct.StringWithSeparator.html -//! [user guide]: https://docs.rs/serde_with/1.9.1/serde_with/guide/index.html +//! [`DisplayFromStr`]: https://docs.rs/serde_with/1.9.2/serde_with/struct.DisplayFromStr.html +//! [`with_prefix!`]: https://docs.rs/serde_with/1.9.2/serde_with/macro.with_prefix.html +//! [display_fromstr]: https://docs.rs/serde_with/1.9.2/serde_with/rust/display_fromstr/index.html +//! [feature flags]: https://docs.rs/serde_with/1.9.2/serde_with/guide/feature_flags/index.html +//! [skip_serializing_none]: https://docs.rs/serde_with/1.9.2/serde_with/attr.skip_serializing_none.html +//! [StringWithSeparator]: https://docs.rs/serde_with/1.9.2/serde_with/rust/struct.StringWithSeparator.html +//! [user guide]: https://docs.rs/serde_with/1.9.2/serde_with/guide/index.html //! [with-annotation]: https://serde.rs/field-attrs.html#with -//! [as-annotation]: https://docs.rs/serde_with/1.9.1/serde_with/guide/serde_as/index.html +//! [as-annotation]: https://docs.rs/serde_with/1.9.2/serde_with/guide/serde_as/index.html #[doc(hidden)] pub extern crate serde; @@ -344,7 +344,7 @@ impl Separator for CommaSeparator { /// # } /// ``` /// -/// [serde_as]: https://docs.rs/serde_with/1.9.1/serde_with/attr.serde_as.html +/// [serde_as]: https://docs.rs/serde_with/1.9.2/serde_with/attr.serde_as.html #[derive(Copy, Clone, Debug, Default)] pub struct As(PhantomData); @@ -810,7 +810,7 @@ pub struct BytesOrString; /// ``` /// /// [`chrono::Duration`]: chrono_crate::Duration -/// [feature flag]: https://docs.rs/serde_with/1.9.1/serde_with/guide/feature_flags/index.html +/// [feature flag]: https://docs.rs/serde_with/1.9.2/serde_with/guide/feature_flags/index.html #[derive(Copy, Clone, Debug, Default)] pub struct DurationSeconds< FORMAT: formats::Format = u64, @@ -936,7 +936,7 @@ pub struct DurationSeconds< /// ``` /// /// [`chrono::Duration`]: chrono_crate::Duration -/// [feature flag]: https://docs.rs/serde_with/1.9.1/serde_with/guide/feature_flags/index.html +/// [feature flag]: https://docs.rs/serde_with/1.9.2/serde_with/guide/feature_flags/index.html #[derive(Copy, Clone, Debug, Default)] pub struct DurationSecondsWithFrac< FORMAT: formats::Format = f64, @@ -1133,7 +1133,7 @@ pub struct DurationNanoSecondsWithFrac< /// /// [`SystemTime`]: std::time::SystemTime /// [DateTime]: chrono_crate::DateTime -/// [feature flag]: https://docs.rs/serde_with/1.9.1/serde_with/guide/feature_flags/index.html +/// [feature flag]: https://docs.rs/serde_with/1.9.2/serde_with/guide/feature_flags/index.html #[derive(Copy, Clone, Debug, Default)] pub struct TimestampSeconds< FORMAT: formats::Format = i64, @@ -1262,7 +1262,7 @@ pub struct TimestampSeconds< /// /// [`SystemTime`]: std::time::SystemTime /// [DateTime]: chrono_crate::DateTime -/// [feature flag]: https://docs.rs/serde_with/1.9.1/serde_with/guide/feature_flags/index.html +/// [feature flag]: https://docs.rs/serde_with/1.9.2/serde_with/guide/feature_flags/index.html #[derive(Copy, Clone, Debug, Default)] pub struct TimestampSecondsWithFrac< FORMAT: formats::Format = f64,