diff options
author | Felix Lange <fjl@twurst.com> | 2017-03-27 17:52:39 +0800 |
---|---|---|
committer | Felix Lange <fjl@twurst.com> | 2017-03-27 19:29:01 +0800 |
commit | aa9a78e4639e8594849be3fa0f92d7f91f67d528 (patch) | |
tree | d1e84875024142fb9535c27cf6aa168c042f279a /core/types/gen_log_json.go | |
parent | 7419d0c38291236ecc4e54b1a905d5cbcbe065a4 (diff) | |
download | go-tangerine-aa9a78e4639e8594849be3fa0f92d7f91f67d528.tar.gz go-tangerine-aa9a78e4639e8594849be3fa0f92d7f91f67d528.tar.zst go-tangerine-aa9a78e4639e8594849be3fa0f92d7f91f67d528.zip |
core, core/types: use non-pointer receiver for Marshal* methods
Regenerated with fjl/gencodec@1a75a2161009
Also add ,omitempty to optional GenesisAccount fields.
Diffstat (limited to 'core/types/gen_log_json.go')
-rw-r--r-- | core/types/gen_log_json.go | 36 |
1 files changed, 18 insertions, 18 deletions
diff --git a/core/types/gen_log_json.go b/core/types/gen_log_json.go index ef2cdfd89..5c8032953 100644 --- a/core/types/gen_log_json.go +++ b/core/types/gen_log_json.go @@ -1,4 +1,4 @@ -// generated by github.com/fjl/gencodec, do not edit. +// Code generated by github.com/fjl/gencodec. DO NOT EDIT. package types @@ -10,28 +10,28 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" ) -func (l *Log) MarshalJSON() ([]byte, error) { +func (l Log) MarshalJSON() ([]byte, error) { type LogJSON struct { - Address *common.Address `json:"address"` - Topics []common.Hash `json:"topics"` - Data hexutil.Bytes `json:"data"` - BlockNumber *hexutil.Uint64 `json:"blockNumber" optional:"yes"` - TxHash *common.Hash `json:"transactionHash"` - TxIndex *hexutil.Uint `json:"transactionIndex"` - BlockHash *common.Hash `json:"blockHash" optional:"yes"` - Index *hexutil.Uint `json:"logIndex"` - Removed *bool `json:"removed" optional:"yes"` + Address common.Address `json:"address"` + Topics []common.Hash `json:"topics"` + Data hexutil.Bytes `json:"data"` + BlockNumber hexutil.Uint64 `json:"blockNumber" optional:"yes"` + TxHash common.Hash `json:"transactionHash"` + TxIndex hexutil.Uint `json:"transactionIndex"` + BlockHash common.Hash `json:"blockHash" optional:"yes"` + Index hexutil.Uint `json:"logIndex"` + Removed bool `json:"removed" optional:"yes"` } var enc LogJSON - enc.Address = &l.Address + enc.Address = l.Address enc.Topics = l.Topics enc.Data = l.Data - enc.BlockNumber = (*hexutil.Uint64)(&l.BlockNumber) - enc.TxHash = &l.TxHash - enc.TxIndex = (*hexutil.Uint)(&l.TxIndex) - enc.BlockHash = &l.BlockHash - enc.Index = (*hexutil.Uint)(&l.Index) - enc.Removed = &l.Removed + enc.BlockNumber = hexutil.Uint64(l.BlockNumber) + enc.TxHash = l.TxHash + enc.TxIndex = hexutil.Uint(l.TxIndex) + enc.BlockHash = l.BlockHash + enc.Index = hexutil.Uint(l.Index) + enc.Removed = l.Removed return json.Marshal(&enc) } |