bracket verify_attributes/3 interrupts with allocation and deallocation of stack frames.

This commit is contained in:
Mark Thom
2019-02-11 21:21:13 -07:00
parent c3a5f25239
commit e36485533d
7 changed files with 70 additions and 24 deletions

View File

@@ -450,9 +450,15 @@ impl MachineState {
CWILCallPolicy.")
},
&SystemClauseType::RestoreCodePtrFromSpecialFormCP => {
self.p = self.attr_var_init.pop_code_ptr();
mem::swap(&mut self.registers, &mut self.attr_var_init.registers);
let e = self.e;
for i in 1 .. self.and_stack[e].len() + 1 {
self[RegType::Temp(i)] = self.and_stack[e][i].clone();
}
self.p = CodePtr::Local(self.and_stack[e].special_form_cp);
self.deallocate();
return Ok(());
},
&SystemClauseType::RestoreCutPolicy => {