Add Vm::frames(&self) function

Signed-off-by: Alek Ratzloff <alekratz@gmail.com>
This commit is contained in:
2020-09-14 16:37:16 -07:00
parent fdbb0a1307
commit ef38680fe5

View File

@@ -48,6 +48,11 @@ impl<'c> Vm<'c> {
self.frames.last_mut() self.frames.last_mut()
} }
/// Gets the list of stack frames.
pub fn frames(&self) -> &Vec<Frame> {
&self.frames
}
/// Gets the stack. /// Gets the stack.
pub fn stack(&self) -> &Vec<ObjRef> { pub fn stack(&self) -> &Vec<ObjRef> {
&self.stack &self.stack