16 lines
355 B
Go
16 lines
355 B
Go
package vm
|
|
|
|
type stackFrame struct {
|
|
previousFunctionIndex int64
|
|
previousInstructionIndex int64
|
|
functionMemory *memory
|
|
}
|
|
|
|
func newStackFrame(state *State) *stackFrame {
|
|
return &stackFrame{
|
|
previousFunctionIndex: state.functionIndex,
|
|
previousInstructionIndex: state.instructionIndex,
|
|
functionMemory: newMemory(16),
|
|
}
|
|
}
|