diff --git a/module/core/derive_tools_meta/src/lib.rs b/module/core/derive_tools_meta/src/lib.rs index 798ee1c2bd..c56791014e 100644 --- a/module/core/derive_tools_meta/src/lib.rs +++ b/module/core/derive_tools_meta/src/lib.rs @@ -16,6 +16,7 @@ feature = "derive_index", feature = "derive_index_mut", feature = "derive_inner_from", + feature = "derive_new", feature = "derive_variadic_from", feature = "derive_phantom" ) @@ -34,6 +35,7 @@ mod derive; // feature = "derive_index", // feature = "derive_index_mut", // feature = "derive_inner_from", +// feature = "derive_new", // feature = "derive_variadic_from", // feature = "derive_phantom" // ) diff --git a/module/core/macro_tools/Readme.md b/module/core/macro_tools/Readme.md index 1121555152..6d148200b3 100644 --- a/module/core/macro_tools/Readme.md +++ b/module/core/macro_tools/Readme.md @@ -15,9 +15,9 @@ The purpose of `typ::type_parameters` is to extract type parameters from a given In this example, we generate a type `core::option::Option` and extract its type parameters. ```rust -#[ cfg( not( feature = "enabled" ) ) ] +#[ cfg( not( all( feature = "enabled", feature = "typ" ) ) ) ] fn main(){} -#[ cfg( feature = "enabled" ) ] +#[ cfg( all( feature = "enabled", feature = "typ" ) ) ] fn main() { // Import necessary macros and modules from the `macro_tools` crate. @@ -80,9 +80,9 @@ defined in other crates. ```rust -#[ cfg( not( all( feature = "enabled", debug_assertions ) ) ) ] +#[ cfg( not( all( feature = "enabled", feature = "attr_prop", debug_assertions ) ) ) ] fn main(){} -#[ cfg( all( feature = "enabled", debug_assertions ) ) ] +#[ cfg( all( feature = "enabled", feature = "attr_prop", debug_assertions ) ) ] fn main() { diff --git a/module/core/macro_tools/examples/macro_tools_attr_prop.rs b/module/core/macro_tools/examples/macro_tools_attr_prop.rs index 3c18928fd1..b5369750d5 100644 --- a/module/core/macro_tools/examples/macro_tools_attr_prop.rs +++ b/module/core/macro_tools/examples/macro_tools_attr_prop.rs @@ -26,9 +26,9 @@ //! defined in other crates. //! -#[ cfg( not( all( feature = "enabled", debug_assertions ) ) ) ] +#[ cfg( not( all( feature = "enabled", feature = "attr_prop", debug_assertions ) ) ) ] fn main(){} -#[ cfg( all( feature = "enabled", debug_assertions ) ) ] +#[ cfg( all( feature = "enabled", feature = "attr_prop", debug_assertions ) ) ] fn main() { diff --git a/module/core/macro_tools/examples/macro_tools_trivial.rs b/module/core/macro_tools/examples/macro_tools_trivial.rs index e92559b193..c0a1e27982 100644 --- a/module/core/macro_tools/examples/macro_tools_trivial.rs +++ b/module/core/macro_tools/examples/macro_tools_trivial.rs @@ -6,9 +6,9 @@ //! In this example, we generate a type `core::option::Option` and extract its type parameters. //! -#[ cfg( not( feature = "enabled" ) ) ] +#[ cfg( not( all( feature = "enabled", feature = "typ" ) ) ) ] fn main(){} -#[ cfg( feature = "enabled" ) ] +#[ cfg( all( feature = "enabled", feature = "typ" ) ) ] fn main() { // Import necessary macros and modules from the `macro_tools` crate. diff --git a/module/core/macro_tools/tests/inc/mod.rs b/module/core/macro_tools/tests/inc/mod.rs index 198ab61378..c28692fdf0 100644 --- a/module/core/macro_tools/tests/inc/mod.rs +++ b/module/core/macro_tools/tests/inc/mod.rs @@ -12,23 +12,39 @@ mod if_enabled use super::*; + #[ cfg( feature = "attr" ) ] mod attr_test; + #[ cfg( feature = "attr_prop" ) ] mod attr_prop_test; mod basic_test; + #[ cfg( feature = "ct" ) ] mod compile_time_test; + #[ cfg( feature = "container_kind" ) ] mod container_kind_test; + #[ cfg( feature = "derive" ) ] mod derive_test; + #[ cfg( feature = "diag" ) ] mod diag_test; mod drop_test; + #[ cfg( feature = "equation" ) ] mod equation_test; + #[ cfg( feature = "generic_args" ) ] mod generic_args_test; + #[ cfg( feature = "generic_params" ) ] mod generic_params_test; + #[ cfg( feature = "item" ) ] mod item_test; + #[ cfg( feature = "item_struct" ) ] mod item_struct_test; + #[ cfg( feature = "phantom" ) ] mod phantom_test; + #[ cfg( feature = "quantifier" ) ] mod quantifier_test; + #[ cfg( feature = "struct_like" ) ] mod struct_like_test; + #[ cfg( feature = "tokens" ) ] mod tokens_test; + #[ cfg( feature = "typ" ) ] mod typ_test; }