vm: fix elements counting for isolated calls
The map and the counter are VM-wide, not context-specific, that's the whole point of them.
This commit is contained in:
parent
3d62db4f34
commit
35c60cd8f4
1 changed files with 2 additions and 2 deletions
|
@ -1391,8 +1391,8 @@ func (v *VM) execute(ctx *Context, op opcode.Opcode, parameter []byte) (err erro
|
|||
newCtx.hasDynamicInvoke = hasDynamicInvoke
|
||||
}
|
||||
newCtx.rvcount = rvcount
|
||||
newCtx.estack = NewStack("evaluation")
|
||||
newCtx.astack = NewStack("alt")
|
||||
newCtx.estack = v.newItemStack("evaluation")
|
||||
newCtx.astack = v.newItemStack("alt")
|
||||
// Going backwards to naturally push things onto the new stack.
|
||||
for i := pcount; i > 0; i-- {
|
||||
elem := v.estack.RemoveAt(i - 1)
|
||||
|
|
Loading…
Reference in a new issue