diff --git a/Cargo.toml b/Cargo.toml index 7edaf48..8e3f3bc 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -4,7 +4,7 @@ members = [ "strong-type-derive", "strong-type-tests" ] -resolver = "2" +resolver = "3" [patch.crates-io] strong-type = { path = "strong-type" } diff --git a/strong-type-derive/Cargo.toml b/strong-type-derive/Cargo.toml index c84476f..efc20e3 100644 --- a/strong-type-derive/Cargo.toml +++ b/strong-type-derive/Cargo.toml @@ -1,8 +1,8 @@ [package] name = "strong-type-derive" description = "Macro implemenation for #[derive(StrongType)]" -version = "0.12.2" -edition = "2021" +version = "0.12.3" +edition = "2024" license = "MIT OR Apache-2.0" keywords = ["primitive", "string", "strongly-typed"] diff --git a/strong-type-derive/src/detail/mod.rs b/strong-type-derive/src/detail/mod.rs index 4b0c190..868c032 100644 --- a/strong-type-derive/src/detail/mod.rs +++ b/strong-type-derive/src/detail/mod.rs @@ -36,5 +36,5 @@ pub(crate) use hash::implement_hash; pub(crate) use nan::implement_nan; pub(crate) use negate::implement_negate; pub(crate) use scalable::implement_scalable; -pub(crate) use underlying_type_utils::{get_type, TypeInfo, UnderlyingType, ValueTypeGroup}; -pub(crate) use utils::{get_attributes, validate_struct, StrongTypeAttributes}; +pub(crate) use underlying_type_utils::{TypeInfo, UnderlyingType, ValueTypeGroup, get_type}; +pub(crate) use utils::{StrongTypeAttributes, get_attributes, validate_struct}; diff --git a/strong-type-derive/src/detail/underlying_type_utils.rs b/strong-type-derive/src/detail/underlying_type_utils.rs index 10b7762..b30273f 100644 --- a/strong-type-derive/src/detail/underlying_type_utils.rs +++ b/strong-type-derive/src/detail/underlying_type_utils.rs @@ -59,7 +59,7 @@ pub(crate) fn get_type_group( fn get_type_ident(input: &DeriveInput) -> Option { if let Data::Struct(ref data_struct) = input.data { - if let Type::Path(ref path) = &data_struct.fields.iter().next().unwrap().ty { + if let Type::Path(path) = &data_struct.fields.iter().next().unwrap().ty { return Some(path.path.segments.last().unwrap().ident.clone()); } } diff --git a/strong-type-derive/src/detail/utils.rs b/strong-type-derive/src/detail/utils.rs index 55946a0..ac541ad 100644 --- a/strong-type-derive/src/detail/utils.rs +++ b/strong-type-derive/src/detail/utils.rs @@ -1,5 +1,5 @@ use crate::detail::underlying_type_utils::get_type_group; -use crate::detail::{get_type, TypeInfo, UnderlyingType}; +use crate::detail::{TypeInfo, UnderlyingType, get_type}; use syn::{Data, DeriveInput, Fields}; pub(crate) struct StrongTypeAttributes { diff --git a/strong-type-derive/src/lib.rs b/strong-type-derive/src/lib.rs index 0d06ed1..1cb66dc 100644 --- a/strong-type-derive/src/lib.rs +++ b/strong-type-derive/src/lib.rs @@ -2,7 +2,7 @@ mod detail; mod strong_type; use proc_macro::TokenStream; -use syn::{parse_macro_input, DeriveInput}; +use syn::{DeriveInput, parse_macro_input}; use crate::strong_type::expand_strong_type; diff --git a/strong-type-derive/src/strong_type.rs b/strong-type-derive/src/strong_type.rs index e39cb56..79a4799 100644 --- a/strong-type-derive/src/strong_type.rs +++ b/strong-type-derive/src/strong_type.rs @@ -1,12 +1,12 @@ use crate::detail::{ - get_attributes, implement_addable, implement_arithmetic, implement_basic, - implement_basic_primitive, implement_basic_string, implement_bit_shift, implement_bool_ops, - implement_constants, implement_constants_derived, implement_conversion, implement_display, - implement_hash, implement_infinity, implement_limit, implement_nan, implement_negate, + StrongTypeAttributes, TypeInfo, UnderlyingType, ValueTypeGroup, get_attributes, + implement_addable, implement_arithmetic, implement_basic, implement_basic_primitive, + implement_basic_string, implement_bit_shift, implement_bool_ops, implement_constants, + implement_constants_derived, implement_conversion, implement_display, implement_hash, + implement_infinity, implement_limit, implement_nan, implement_negate, implement_primitive_accessor, implement_primitive_accessor_derived, implement_primitive_str_accessor, implement_primitive_str_accessor_derived, implement_scalable, - implement_str_conversion, validate_struct, StrongTypeAttributes, TypeInfo, UnderlyingType, - ValueTypeGroup, + implement_str_conversion, validate_struct, }; use proc_macro2::TokenStream; use quote::quote; diff --git a/strong-type-tests/Cargo.toml b/strong-type-tests/Cargo.toml index a3d0707..930c662 100644 --- a/strong-type-tests/Cargo.toml +++ b/strong-type-tests/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "strong-type-tests" version = "0.0.0" -edition = "2021" +edition = "2024" publish = false [dependencies] diff --git a/strong-type/Cargo.toml b/strong-type/Cargo.toml index cb6a4c2..9e75384 100644 --- a/strong-type/Cargo.toml +++ b/strong-type/Cargo.toml @@ -1,8 +1,8 @@ [package] name = "strong-type" description = "Procedural macros for naming and strong-typing pritimives and strings" -version = "0.12.2" -edition = "2021" +version = "0.12.3" +edition = "2024" license = "MIT OR Apache-2.0" keywords = ["primitive", "string", "strongly-typed"]