core/types: go generate (#23177)
This commit is contained in:
parent
7522642393
commit
00b922fc5d
@ -18,12 +18,12 @@ func (l Log) MarshalJSON() ([]byte, error) {
|
|||||||
Address common.Address `json:"address" gencodec:"required"`
|
Address common.Address `json:"address" gencodec:"required"`
|
||||||
Topics []common.Hash `json:"topics" gencodec:"required"`
|
Topics []common.Hash `json:"topics" gencodec:"required"`
|
||||||
Data hexutil.Bytes `json:"data" gencodec:"required"`
|
Data hexutil.Bytes `json:"data" gencodec:"required"`
|
||||||
BlockNumber hexutil.Uint64 `json:"blockNumber"`
|
BlockNumber hexutil.Uint64 `json:"blockNumber" rlp:"-"`
|
||||||
TxHash common.Hash `json:"transactionHash" gencodec:"required"`
|
TxHash common.Hash `json:"transactionHash" gencodec:"required" rlp:"-"`
|
||||||
TxIndex hexutil.Uint `json:"transactionIndex"`
|
TxIndex hexutil.Uint `json:"transactionIndex" rlp:"-"`
|
||||||
BlockHash common.Hash `json:"blockHash"`
|
BlockHash common.Hash `json:"blockHash" rlp:"-"`
|
||||||
Index hexutil.Uint `json:"logIndex"`
|
Index hexutil.Uint `json:"logIndex" rlp:"-"`
|
||||||
Removed bool `json:"removed"`
|
Removed bool `json:"removed" rlp:"-"`
|
||||||
}
|
}
|
||||||
var enc Log
|
var enc Log
|
||||||
enc.Address = l.Address
|
enc.Address = l.Address
|
||||||
@ -44,12 +44,12 @@ func (l *Log) UnmarshalJSON(input []byte) error {
|
|||||||
Address *common.Address `json:"address" gencodec:"required"`
|
Address *common.Address `json:"address" gencodec:"required"`
|
||||||
Topics []common.Hash `json:"topics" gencodec:"required"`
|
Topics []common.Hash `json:"topics" gencodec:"required"`
|
||||||
Data *hexutil.Bytes `json:"data" gencodec:"required"`
|
Data *hexutil.Bytes `json:"data" gencodec:"required"`
|
||||||
BlockNumber *hexutil.Uint64 `json:"blockNumber"`
|
BlockNumber *hexutil.Uint64 `json:"blockNumber" rlp:"-"`
|
||||||
TxHash *common.Hash `json:"transactionHash" gencodec:"required"`
|
TxHash *common.Hash `json:"transactionHash" gencodec:"required" rlp:"-"`
|
||||||
TxIndex *hexutil.Uint `json:"transactionIndex"`
|
TxIndex *hexutil.Uint `json:"transactionIndex" rlp:"-"`
|
||||||
BlockHash *common.Hash `json:"blockHash"`
|
BlockHash *common.Hash `json:"blockHash" rlp:"-"`
|
||||||
Index *hexutil.Uint `json:"logIndex"`
|
Index *hexutil.Uint `json:"logIndex" rlp:"-"`
|
||||||
Removed *bool `json:"removed"`
|
Removed *bool `json:"removed" rlp:"-"`
|
||||||
}
|
}
|
||||||
var dec Log
|
var dec Log
|
||||||
if err := json.Unmarshal(input, &dec); err != nil {
|
if err := json.Unmarshal(input, &dec); err != nil {
|
||||||
|
Loading…
Reference in New Issue
Block a user