lol, fix error

This commit is contained in:
2024-11-27 01:41:11 -05:00
parent eeacbc6473
commit b953a372c2
3 changed files with 0 additions and 14 deletions

View File

@@ -410,13 +410,6 @@ impl Executor {
Ok(Value::Nil) Ok(Value::Nil)
} }
ParseTree::NonCall(name) => {
let obj = self.get_object_mut(&name)?;
let v = obj.lock().unwrap().eval()?;
Ok(v)
}
ParseTree::_Local(_idx) => todo!(), ParseTree::_Local(_idx) => todo!(),
ParseTree::GeneratedFunction(function) => Ok(Value::Function(function.globals(self.globals.clone()).locals(self.locals.clone()))), ParseTree::GeneratedFunction(function) => Ok(Value::Function(function.globals(self.globals.clone()).locals(self.locals.clone()))),
} }

View File

@@ -119,12 +119,6 @@ impl Function {
ParseTree::Value(_) => body, ParseTree::Value(_) => body,
ParseTree::Nop => body, ParseTree::Nop => body,
ParseTree::Export(_) => body, ParseTree::Export(_) => body,
ParseTree::NonCall(ref var) => if let Some(idx) =
args.into_iter().position(|r| *r == *var) {
Box::new(ParseTree::_Local(idx))
} else {
body
}
ParseTree::GeneratedFunction(_) => todo!(), ParseTree::GeneratedFunction(_) => todo!(),
} }
} }

View File

@@ -29,7 +29,6 @@ pub(crate) enum ParseTree {
GeneratedFunction(Function), GeneratedFunction(Function),
Nop, Nop,
NonCall(String),
Export(Vec<String>), Export(Vec<String>),
} }