Add initial tests for type checker
This commit is contained in:
parent
50bc35753a
commit
b0420a9a5f
5 changed files with 280 additions and 33 deletions
|
@ -1,5 +1,13 @@
|
|||
use std::fmt;
|
||||
|
||||
#[derive(PartialEq, Debug)]
|
||||
pub enum Type {
|
||||
Int,
|
||||
Bool,
|
||||
Func(Vec<Type>, Box<Type>),
|
||||
Unit,
|
||||
}
|
||||
|
||||
#[derive(PartialEq, PartialOrd, Debug, Copy, Clone)]
|
||||
pub enum Value {
|
||||
Int(i64),
|
||||
|
|
Reference in a new issue