vm: move InteropNameToID to a separate package
This commit is contained in:
parent
9cc6e22365
commit
f3650e20b0
14 changed files with 60 additions and 52 deletions
|
@ -4,8 +4,8 @@ import (
|
|||
"errors"
|
||||
|
||||
"github.com/nspcc-dev/neo-go/pkg/core/interop"
|
||||
"github.com/nspcc-dev/neo-go/pkg/core/interop/interopnames"
|
||||
"github.com/nspcc-dev/neo-go/pkg/vm"
|
||||
"github.com/nspcc-dev/neo-go/pkg/vm/emit"
|
||||
"github.com/nspcc-dev/neo-go/pkg/vm/stackitem"
|
||||
)
|
||||
|
||||
|
@ -27,7 +27,7 @@ func Invoke(ic *interop.Context) error {
|
|||
cb.LoadContext(ic.VM, args)
|
||||
switch t := cb.(type) {
|
||||
case *MethodCallback:
|
||||
id := emit.InteropNameToID([]byte("System.Contract.Call"))
|
||||
id := interopnames.ToID([]byte("System.Contract.Call"))
|
||||
return ic.SyscallHandler(ic.VM, id)
|
||||
case *SyscallCallback:
|
||||
return ic.SyscallHandler(ic.VM, t.desc.ID)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue