diff options
author | Felix Lange <fjl@users.noreply.github.com> | 2018-01-08 20:15:57 +0800 |
---|---|---|
committer | Péter Szilágyi <peterke@gmail.com> | 2018-01-08 20:15:57 +0800 |
commit | 5c2f1e00148f16655d3fb63b93920b1108165c56 (patch) | |
tree | f3b453e05a8da60ceb006b5899554f8fbad86cf4 /core/types | |
parent | a139041d409d0ffaf81c7cf931c6b24299a05705 (diff) | |
download | dexon-5c2f1e00148f16655d3fb63b93920b1108165c56.tar dexon-5c2f1e00148f16655d3fb63b93920b1108165c56.tar.gz dexon-5c2f1e00148f16655d3fb63b93920b1108165c56.tar.bz2 dexon-5c2f1e00148f16655d3fb63b93920b1108165c56.tar.lz dexon-5c2f1e00148f16655d3fb63b93920b1108165c56.tar.xz dexon-5c2f1e00148f16655d3fb63b93920b1108165c56.tar.zst dexon-5c2f1e00148f16655d3fb63b93920b1108165c56.zip |
all: update generated code (#15808)
* core/types, core/vm, eth, tests: regenerate gencodec files
* Makefile: update devtools target
Install protoc-gen-go and print reminders about npm, solc and protoc.
Also switch to github.com/kevinburke/go-bindata because it's more
maintained.
* contracts/ens: update contracts and regenerate with solidity v0.4.19
The newer upstream version of the FIFSRegistrar contract doesn't set the
resolver anymore. The resolver is now deployed separately.
* contracts/release: regenerate with solidity v0.4.19
* contracts/chequebook: fix fallback and regenerate with solidity v0.4.19
The contract didn't have a fallback function, payments would be rejected
when compiled with newer solidity. References to 'mortal' and 'owned'
use the local file system so we can compile without network access.
* p2p/discv5: regenerate with recent stringer
* cmd/faucet: regenerate
* dashboard: regenerate
* eth/tracers: regenerate
* internal/jsre/deps: regenerate
* dashboard: avoid sed -i because it's not portable
* accounts/usbwallet/internal/trezor: fix go generate warnings
Diffstat (limited to 'core/types')
-rw-r--r-- | core/types/block.go | 4 | ||||
-rw-r--r-- | core/types/gen_header_json.go | 6 | ||||
-rw-r--r-- | core/types/gen_log_json.go | 2 | ||||
-rw-r--r-- | core/types/gen_receipt_json.go | 2 | ||||
-rw-r--r-- | core/types/gen_tx_json.go | 2 |
5 files changed, 12 insertions, 4 deletions
diff --git a/core/types/block.go b/core/types/block.go index 9be62b9e0..ffe317342 100644 --- a/core/types/block.go +++ b/core/types/block.go @@ -89,8 +89,8 @@ type Header struct { type headerMarshaling struct { Difficulty *hexutil.Big Number *hexutil.Big - GasLimit *hexutil.Uint64 - GasUsed *hexutil.Uint64 + GasLimit hexutil.Uint64 + GasUsed hexutil.Uint64 Time *hexutil.Big Extra hexutil.Bytes Hash common.Hash `json:"hash"` // adds call to Hash() in MarshalJSON diff --git a/core/types/gen_header_json.go b/core/types/gen_header_json.go index 8af059104..eacca1ba5 100644 --- a/core/types/gen_header_json.go +++ b/core/types/gen_header_json.go @@ -11,6 +11,8 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" ) +var _ = (*headerMarshaling)(nil) + func (h Header) MarshalJSON() ([]byte, error) { type Header struct { ParentHash common.Hash `json:"parentHash" gencodec:"required"` @@ -111,11 +113,11 @@ func (h *Header) UnmarshalJSON(input []byte) error { if dec.GasLimit == nil { return errors.New("missing required field 'gasLimit' for Header") } - h.GasLimit = (uint64)(*dec.GasLimit) + h.GasLimit = uint64(*dec.GasLimit) if dec.GasUsed == nil { return errors.New("missing required field 'gasUsed' for Header") } - h.GasUsed = (uint64)(*dec.GasUsed) + h.GasUsed = uint64(*dec.GasUsed) if dec.Time == nil { return errors.New("missing required field 'timestamp' for Header") } diff --git a/core/types/gen_log_json.go b/core/types/gen_log_json.go index 92c699c2a..c9c2d3d25 100644 --- a/core/types/gen_log_json.go +++ b/core/types/gen_log_json.go @@ -10,6 +10,8 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" ) +var _ = (*logMarshaling)(nil) + func (l Log) MarshalJSON() ([]byte, error) { type Log struct { Address common.Address `json:"address" gencodec:"required"` diff --git a/core/types/gen_receipt_json.go b/core/types/gen_receipt_json.go index 520966874..1c9d8af93 100644 --- a/core/types/gen_receipt_json.go +++ b/core/types/gen_receipt_json.go @@ -10,6 +10,8 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" ) +var _ = (*receiptMarshaling)(nil) + func (r Receipt) MarshalJSON() ([]byte, error) { type Receipt struct { PostState hexutil.Bytes `json:"root"` diff --git a/core/types/gen_tx_json.go b/core/types/gen_tx_json.go index a82822c36..035c26540 100644 --- a/core/types/gen_tx_json.go +++ b/core/types/gen_tx_json.go @@ -11,6 +11,8 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" ) +var _ = (*txdataMarshaling)(nil) + func (t txdata) MarshalJSON() ([]byte, error) { type txdata struct { AccountNonce hexutil.Uint64 `json:"nonce" gencodec:"required"` |