github.com/0xsequence/ethkit@v1.25.0/ethcoder/types.go (about) 1 package ethcoder 2 3 import "github.com/0xsequence/ethkit/go-ethereum/accounts/abi" 4 5 func MustNewType(str string) abi.Type { 6 typ, err := abi.NewType(str, "", nil) 7 if err != nil { 8 panic(err) 9 } 10 return typ 11 } 12 13 func MustNewArrayTypeTuple(components []abi.ArgumentMarshaling) abi.Type { 14 typ, err := abi.NewType("tuple[]", "", components) 15 if err != nil { 16 panic(err) 17 } 18 return typ 19 }