leo_ast::valueMacro implement_const_binary
Source macro_rules! implement_const_binary {
(
@overflowing
name: $name:ident,
method: $method:ident,
string: $str:expr,
patterns: [$(
// lhs, rhs, out, method left, method right
[$lhs:ident, [$($rhs:ident),+], $out:ident, $m_lhs:ty, $m_rhs:ty]
),+]
) => { ... };
(
@non-overflowing
name: $name:ident,
method: $method:ident,
patterns: [$(
// lhs, rhs, out, method left, method right, method output
[$lhs:ident, [$($rhs:ident),+], $out:ident, $m_lhs:ty, $m_rhs:ty]
),+]
) => { ... };
(
@cmp
name: $name:ident,
method: $method:ident,
string: $str:expr,
patterns: [$(
// lhs, rhs, out, method left, method right, method output
[$lhs:ident, [$($rhs:ident),+], $out:ident, $m_lhs:ty, $m_rhs:ty]
),+]
) => { ... };
(
name: $name:ident,
patterns: [$([
types: $lhs:ident, [$($rhs:ident),+], $out:ident,
logic: $logic:expr
]),+]
) => { ... };
}