[][src]Macro peepmatic_traits::define_operator

macro_rules! define_operator {
    (
        $( #[$attr:meta] )*
        $operator:ident {
            $(
                $keywrord:ident => $variant:ident {
                    $( immediates( $($immediate:ident),* ); )?
                    $( parameters( $($parameter:ident),* ); )?
                    result( $result:ident );
                    $( is_reduce($is_reduce:expr); )?
                    $( is_extend($is_extend:expr); )?
                }
            )*
        }
        $( parse_cfg($parse_cfg:meta); )?
    ) => { ... };
}

Define an operator type, as well as its parsing and typing rules.