diff options
author | Bas van Kervel <basvankervel@gmail.com> | 2017-02-07 01:16:56 +0800 |
---|---|---|
committer | Bas van Kervel <basvankervel@gmail.com> | 2017-02-07 01:16:56 +0800 |
commit | d0eeb3ebdcb58f62ab4c542aef9e865c10797175 (patch) | |
tree | 2d658163a90fa37b3bdf0d1133a25e3f52d0d92b | |
parent | 296450451b090393b2dd11d057c5b72cb4d92356 (diff) | |
download | go-tangerine-d0eeb3ebdcb58f62ab4c542aef9e865c10797175.tar go-tangerine-d0eeb3ebdcb58f62ab4c542aef9e865c10797175.tar.gz go-tangerine-d0eeb3ebdcb58f62ab4c542aef9e865c10797175.tar.bz2 go-tangerine-d0eeb3ebdcb58f62ab4c542aef9e865c10797175.tar.lz go-tangerine-d0eeb3ebdcb58f62ab4c542aef9e865c10797175.tar.xz go-tangerine-d0eeb3ebdcb58f62ab4c542aef9e865c10797175.tar.zst go-tangerine-d0eeb3ebdcb58f62ab4c542aef9e865c10797175.zip |
cmd/abigen: parse contract name as abi identifier
-rw-r--r-- | cmd/abigen/main.go | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/cmd/abigen/main.go b/cmd/abigen/main.go index dfbd025da..3a1ae6f4c 100644 --- a/cmd/abigen/main.go +++ b/cmd/abigen/main.go @@ -94,7 +94,9 @@ func main() { abi, _ := json.Marshal(contract.Info.AbiDefinition) // Flatten the compiler parse abis = append(abis, string(abi)) bins = append(bins, contract.Code) - types = append(types, name) + + nameParts := strings.Split(name, ":") + types = append(types, nameParts[len(nameParts)-1]) } } else { // Otherwise load up the ABI, optional bytecode and type name from the parameters |