diff --git a/src/main.rs b/src/main.rs index 05782302..94626c8b 100644 --- a/src/main.rs +++ b/src/main.rs @@ -10,6 +10,7 @@ mod repl; mod variables; use clap::{App, Arg}; +use interpret::Scope; use logos::Source; use parser::Parser; @@ -38,7 +39,11 @@ fn main() { let mut parser = Parser::new(&source); let ast = parser.init(); match ast { - Ok(ast) => println!("{:#?}", ast), + Ok(ast) => { + println!("{:#?}", ast); + let mut ctx = Scope::new(); + println!("{:?}", ctx.eval_items(&ast)); + } Err(e) => { println!( "Error `{:?}` occured at span: {:?} = `{:?}`",