Commit 2d4d2366 authored by Nick Mathewson's avatar Nick Mathewson 🤹
Browse files

tor-config::derive: use cfg(true) and cfg(false)

Rust 1.88 added these, so we no longer have to use `any()` for false
and `all()` for true.
parent be10d988
Loading
Loading
Loading
Loading
+4 −7
Original line number Diff line number Diff line
@@ -2506,17 +2506,15 @@ mod test {
        #[derive(Deftly, Clone, Debug, PartialEq)]
        #[derive_deftly(TorConfig)]
        pub(super) struct CfgEnabled {
            // MSRV 1.88: Use "true" instead.
            #[deftly(tor_config(
                default,
                cfg = "all()",
                cfg = "true",
                cfg_desc = "with eschaton immenentization"
            ))]
            pub(super) flower_power: u32,
            // MSRV 1.88: Use "true" instead.
            #[deftly(tor_config(
                default,
                cfg = "all()",
                cfg = "true",
                cfg_reject,
                cfg_desc = "with eschaton immenentization"
            ))]
@@ -2526,16 +2524,15 @@ mod test {
        #[derive(Deftly, Clone, Debug, PartialEq)]
        #[derive_deftly(TorConfig)]
        pub(super) struct CfgDisabled {
            // MSRV 1.88: Use "false" instead.
            #[deftly(tor_config(
                default,
                cfg = "any()",
                cfg = "false",
                cfg_desc = "with resublimated thiotimoline"
            ))]
            pub(super) time_travel: u32,
            #[deftly(tor_config(
                default,
                cfg = "any()",
                cfg = "false",
                cfg_reject,
                cfg_desc = "with resublimated thiotimoline"
            ))]