Add type-checking for the majority of language features
This commit is contained in:
parent
b0420a9a5f
commit
dc9cfcd211
4 changed files with 145 additions and 14 deletions
|
@ -51,7 +51,9 @@ impl<'source> SymTab<'source, Type> {
|
|||
(">", Func(vec![Int, Int], Box::new(Bool))),
|
||||
(">=", Func(vec![Int, Int], Box::new(Bool))),
|
||||
("not", Func(vec![Bool], Box::new(Bool))),
|
||||
("neg", Func(vec![Bool], Box::new(Bool))),
|
||||
("neg", Func(vec![Int], Box::new(Int))),
|
||||
("or", Func(vec![Bool, Bool], Box::new(Bool))),
|
||||
("and", Func(vec![Bool, Bool], Box::new(Bool))),
|
||||
]);
|
||||
|
||||
SymTab {
|
||||
|
|
Reference in a new issue