diff --git a/tree_inputs/src/lib.rs b/tree_inputs/src/lib.rs index 688cb4241..18200a324 100644 --- a/tree_inputs/src/lib.rs +++ b/tree_inputs/src/lib.rs @@ -1,4 +1,5 @@ pub mod ast; +pub mod interpreter; pub mod schema; pub type Result = std::result::Result<(), egglog::Error>; diff --git a/tree_inputs/src/schema.rs b/tree_inputs/src/schema.rs index 033072694..2f0e37908 100644 --- a/tree_inputs/src/schema.rs +++ b/tree_inputs/src/schema.rs @@ -11,6 +11,7 @@ pub enum Type { TupleT(Vec>), } +#[derive(Debug, Clone, PartialEq, Eq)] pub enum BinaryOp { Add, Sub, @@ -26,6 +27,7 @@ pub enum UnaryOp { Print, } +#[derive(Debug, Clone, PartialEq, Eq)] pub enum Constant { Int(i64), Bool(bool), @@ -43,11 +45,12 @@ pub enum Assumption { InLoop(RcExpr, RcExpr), } +#[derive(Debug, Clone, PartialEq, Eq)] pub enum Expr { Const(Constant), Bop(BinaryOp, RcExpr, RcExpr), Uop(UnaryOp, RcExpr), - Get(RcExpr, i64), + Get(RcExpr, usize), Read(RcExpr, Type), Call(String, RcExpr), All(Order, Vec),