MCPcopy Create free account
hub / github.com/chain/txvm / peek

Method peek

protocol/txvm/vm.go:251–257  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

249}
250
251func (vm *VM) peek() Item {
252 v, ok := vm.contract.stack.peek(0)
253 if !ok {
254 panic(errors.Wrap(ErrUnderflow, "peeking stack item"))
255 }
256 return v
257}
258
259func (vm *VM) peekNth(n int64) Item {
260 v, ok := vm.contract.stack.peek(n)

Callers 4

peekValueMethod · 0.95
opSeedFunction · 0.45
peekNthMethod · 0.45
opDupFunction · 0.45

Calls 1

WrapFunction · 0.92

Tested by

no test coverage detected