diffgeom/
macros.rs

1#[macro_export]
2macro_rules! mul {
3    ($T1: ty, $T2: ty; $op1: expr, $op2: expr) => {{
4        use std::ops::Mul;
5        <$T1 as Mul<$T2>>::mul($op1, $op2)
6    }};
7}
8
9#[macro_export]
10macro_rules! inner {
11    ($T1: ty, $T2: ty; $I1: ty, $I2: ty; $op1: expr, $op2: expr) => {{
12        use $crate::tensors::InnerProduct;
13        <$T1 as InnerProduct<$T2, $I1, $I2>>::inner_product($op1, $op2)
14    }};
15}