dala/interpreter/expr/
macros.rs

1macro_rules! create_expr_struct {
2    ($struct_name:ident) => {
3        #[derive(Debug, Clone)]
4        pub struct $struct_name {
5            pub pos: Position,
6            pub children: Vec<Box<DalaExpression>>,
7        }
8
9        impl $struct_name {
10            pub fn new(pos: Position, children: Vec<Box<DalaExpression>>) -> Self {
11                Self { pos, children }
12            }
13        }
14    };
15}
16
17pub(crate) use create_expr_struct;