all: switch gas limits from big.Int to uint64

This commit is contained in:
Péter Szilágyi
2017-11-13 13:47:27 +02:00
parent b8caba9709
commit 6f69cdd109
82 changed files with 606 additions and 642 deletions

View File

@ -473,8 +473,8 @@ type blockStats struct {
ParentHash common.Hash `json:"parentHash"`
Timestamp *big.Int `json:"timestamp"`
Miner common.Address `json:"miner"`
GasUsed *big.Int `json:"gasUsed"`
GasLimit *big.Int `json:"gasLimit"`
GasUsed uint64 `json:"gasUsed"`
GasLimit uint64 `json:"gasLimit"`
Diff string `json:"difficulty"`
TotalDiff string `json:"totalDifficulty"`
Txs []txStats `json:"transactions"`
@ -559,8 +559,8 @@ func (s *Service) assembleBlockStats(block *types.Block) *blockStats {
ParentHash: header.ParentHash,
Timestamp: header.Time,
Miner: author,
GasUsed: new(big.Int).Set(header.GasUsed),
GasLimit: new(big.Int).Set(header.GasLimit),
GasUsed: header.GasUsed,
GasLimit: header.GasLimit,
Diff: header.Difficulty.String(),
TotalDiff: td.String(),
Txs: txs,