Macro changed

Source
macro_rules! changed {
    (
        $change:expr;
        //  variant WITH `@` shorthand
        $ty:ident $( . $path:ident )* @ ( $pat:pat ) => $body:block
        $( ; $($rest:tt)* )?
    ) => { ... };
    (
        $change:expr;
        $ty:ident $( . $path:ident )* ( $pat:pat ) => $body:block
        $( ; $($rest:tt)* )?
    ) => { ... };
    ( $change:expr; ) => { ... };
}
Expand description

changed! – flexible, typed diff‑matching macro with zero runtime cost.

  • @ immediately after the path targets the self_ variant of the nested change enum.