More work on evaluating applications
for later testing + to kill a compiler warning
This commit is contained in:
parent
a1b874c891
commit
61795b0331
2
TODO.md
2
TODO.md
@ -42,3 +42,5 @@ struct CompilerPass {
|
|||||||
}
|
}
|
||||||
|
|
||||||
-change "Type...." names in parser.rs to "Anno..." for non-collision with names in typechecking.rs
|
-change "Type...." names in parser.rs to "Anno..." for non-collision with names in typechecking.rs
|
||||||
|
|
||||||
|
* In eval.rs, change `ReplState` to something that assumes no repl
|
||||||
|
@ -137,6 +137,8 @@ impl ReplState {
|
|||||||
Expression(Value(identifier, _), _) => {
|
Expression(Value(identifier, _), _) => {
|
||||||
match self.values.get(&identifier) {
|
match self.values.get(&identifier) {
|
||||||
Some(&ValueEntry::Function { ref body }) => {
|
Some(&ValueEntry::Function { ref body }) => {
|
||||||
|
let new_state = ReplState::new();
|
||||||
|
let sub_ast = AST(body.clone());
|
||||||
println!("LOL ALL FUNCTIONS EVALUATE TO 2!");
|
println!("LOL ALL FUNCTIONS EVALUATE TO 2!");
|
||||||
Ok(FullyEvaluatedExpr::UnsignedInt(2))
|
Ok(FullyEvaluatedExpr::UnsignedInt(2))
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user