Macro k8s_openapi::k8s_match

source ·
macro_rules! k8s_match {
    (@inner { $test:expr } { $($arms:tt)* } { }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_1_24!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_ge_1_24!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_le_1_24!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_1_25!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_ge_1_25!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_le_1_25!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_1_26!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_ge_1_26!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_le_1_26!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_1_27!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_ge_1_27!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_le_1_27!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_1_28!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_ge_1_28!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_le_1_28!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_1_29!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_ge_1_29!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_le_1_29!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_1_30!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_ge_1_30!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { k8s_if_le_1_30!($($arm:tt)*), $($rest:tt)* }) => { ... };
    (@inner { $test:expr } { $($arms:tt)* } { $next_pat:pat $(if $cond:expr)? => $next_expr:expr, $($rest:tt)* }) => { ... };
    ($test:expr, { $($rest:tt)* }) => { ... };
}
Expand description

A macro that emits a match expr with the given test expression and arms. The match arms can be annotated with the other conditional compilation macros in this crate so that they’re only emitted if the predicate is true.