aboutsummaryrefslogtreecommitdiffstats
path: root/src/vm.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/vm.rs')
-rw-r--r--src/vm.rs34
1 files changed, 17 insertions, 17 deletions
diff --git a/src/vm.rs b/src/vm.rs
index 3215797..8b584af 100644
--- a/src/vm.rs
+++ b/src/vm.rs
@@ -198,7 +198,7 @@ impl VM {
}
/// Stop the program, violently
- fn _crash_and_burn(&self) -> ! {
+ fn crash_and_burn(&self) -> ! {
self.print_stack();
println!("\n");
self.frame().block.borrow().debug_print();
@@ -632,22 +632,22 @@ impl VM {
self.pop();
}
- Op::Define(ty) => {
- let ty = self.ty(ty);
- let top_type = self.stack.last().unwrap().into();
- match (ty, top_type) {
- (Type::Unknown, top_type)
- if top_type != Type::Unknown => {}
- (a, b) if a != &b => {
- error!(self,
- ErrorKind::TypeError(
- op,
- vec![a.clone(), b.clone()]),
- format!("Tried to assign a type {:?} to type {:?}.", a, b)
- );
- }
- _ => {}
- }
+ Op::Define(_ty) => {
+ // let ty = self.ty(ty);
+ // let top_type = self.stack.last().unwrap().into();
+ // match (ty, top_type) {
+ // (Type::Unknown, top_type)
+ // if top_type != Type::Unknown => {}
+ // (a, b) if a != &b => {
+ // error!(self,
+ // ErrorKind::TypeError(
+ // op,
+ // vec![a.clone(), b.clone()]),
+ // format!("Tried to assign a type {:?} to type {:?}.", a, b)
+ // );
+ // }
+ // _ => {}
+ // }
}
Op::Call(num_args) => {