From: Mark Thom Date: Fri, 13 Dec 2019 03:34:50 +0000 (-0700) Subject: use Addr::StackCell(0,0) to indicate non-live local variables X-Git-Tag: v0.8.118~29 X-Git-Url: https://git.sagredo.dev/?a=commitdiff_plain;h=a4e352ba0dc8787d412462f32cc388354f15dc88;p=scryer-prolog.git use Addr::StackCell(0,0) to indicate non-live local variables --- diff --git a/src/prolog/machine/stack.rs b/src/prolog/machine/stack.rs index 17ca25ef..2de3582d 100644 --- a/src/prolog/machine/stack.rs +++ b/src/prolog/machine/stack.rs @@ -242,7 +242,7 @@ impl Stack { for idx in 0 .. num_cells { let offset = prelude_size::() + idx * mem::size_of::(); - ptr::write((self.top as usize + offset) as *mut Addr, Addr::HeapCell(0)); + ptr::write((self.top as usize + offset) as *mut Addr, Addr::StackCell(0,0)); } let and_frame = &mut *(self.top as *mut AndFrame); @@ -264,7 +264,7 @@ impl Stack { for idx in 0 .. num_cells { let offset = prelude_size::() + idx * mem::size_of::(); - ptr::write((self.top as usize + offset) as *mut Addr, Addr::HeapCell(0)); + ptr::write((self.top as usize + offset) as *mut Addr, Addr::StackCell(0,0)); } let or_frame = &mut *(self.top as *mut OrFrame);