We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 78a0e52 commit 6968ed6Copy full SHA for 6968ed6
zenlang/src/vm/vm.rs
@@ -188,19 +188,22 @@ impl VM {
188
189
pub fn step(&mut self) -> bool {
190
if self.halted {
191
+ self.gc();
192
return false;
193
}
194
195
let module_index = self.pc.get_high() as usize;
196
let opcode_index = self.pc.get_low();
197
if module_index >= self.modules.len() {
198
self.halted = true;
199
200
201
202
203
let opcodes = core::mem::take(&mut self.modules[module_index].opcodes);
204
if opcode_index >= opcodes.len() as u32 {
205
206
207
208
209
0 commit comments