Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
Geth-Modification
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张蕾
Geth-Modification
Commits
00b922fc
Unverified
Commit
00b922fc
authored
Jul 08, 2021
by
ucwong
Committed by
GitHub
Jul 08, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
core/types: go generate (#23177)
parent
75226423
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
12 deletions
+12
-12
gen_log_json.go
core/types/gen_log_json.go
+12
-12
No files found.
core/types/gen_log_json.go
View file @
00b922fc
...
@@ -18,12 +18,12 @@ func (l Log) MarshalJSON() ([]byte, error) {
...
@@ -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 {
...
@@ -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
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment