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
61602964
Unverified
Commit
61602964
authored
Jun 08, 2022
by
Rajaram Gaunker
Committed by
GitHub
Jun 08, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
core/types: remove unused field 'td' in Block (#25010)
parent
b60a08d2
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
5 deletions
+1
-5
block.go
core/types/block.go
+1
-5
No files found.
core/types/block.go
View file @
61602964
...
@@ -172,10 +172,6 @@ type Block struct {
...
@@ -172,10 +172,6 @@ type Block struct {
hash
atomic
.
Value
hash
atomic
.
Value
size
atomic
.
Value
size
atomic
.
Value
// Td is used by package core to store the total difficulty
// of the chain up to and including the block.
td
*
big
.
Int
// These fields are used by package eth to track
// These fields are used by package eth to track
// inter-peer block relay.
// inter-peer block relay.
ReceivedAt
time
.
Time
ReceivedAt
time
.
Time
...
@@ -197,7 +193,7 @@ type extblock struct {
...
@@ -197,7 +193,7 @@ type extblock struct {
// are ignored and set to values derived from the given txs, uncles
// are ignored and set to values derived from the given txs, uncles
// and receipts.
// and receipts.
func
NewBlock
(
header
*
Header
,
txs
[]
*
Transaction
,
uncles
[]
*
Header
,
receipts
[]
*
Receipt
,
hasher
TrieHasher
)
*
Block
{
func
NewBlock
(
header
*
Header
,
txs
[]
*
Transaction
,
uncles
[]
*
Header
,
receipts
[]
*
Receipt
,
hasher
TrieHasher
)
*
Block
{
b
:=
&
Block
{
header
:
CopyHeader
(
header
)
,
td
:
new
(
big
.
Int
)
}
b
:=
&
Block
{
header
:
CopyHeader
(
header
)}
// TODO: panic if len(txs) != len(receipts)
// TODO: panic if len(txs) != len(receipts)
if
len
(
txs
)
==
0
{
if
len
(
txs
)
==
0
{
...
...
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