MCPcopy Index your code
hub / github.com/chain/Core / op2Div

Function op2Div

protocol/vm/numeric.go:57–67  ·  view source on GitHub ↗
(vm *virtualMachine)

Source from the content-addressed store, hash-verified

55}
56
57func op2Div(vm *virtualMachine) error {
58 err := vm.applyCost(2)
59 if err != nil {
60 return err
61 }
62 n, err := vm.popInt64(true)
63 if err != nil {
64 return err
65 }
66 return vm.pushInt64(n>>1, true)
67}
68
69func opNegate(vm *virtualMachine) error {
70 err := vm.applyCost(2)

Callers

nothing calls this directly

Calls 3

applyCostMethod · 0.80
popInt64Method · 0.80
pushInt64Method · 0.80

Tested by

no test coverage detected