cmd, core, eth, trie: get rid of trie cache generations (#19262)

* cmd, core, eth, trie: get rid of trie cache generations

* core, trie: get rid of remainder of cache gen boilerplate
This commit is contained in:
Péter Szilágyi
2019-03-14 15:25:12 +02:00
committed by GitHub
parent e270a753be
commit 91eec1251c
21 changed files with 100 additions and 332 deletions

View File

@@ -28,7 +28,7 @@ import (
)
func newEmptySecure() *SecureTrie {
trie, _ := NewSecure(common.Hash{}, NewDatabase(memorydb.New()), 0)
trie, _ := NewSecure(common.Hash{}, NewDatabase(memorydb.New()))
return trie
}
@@ -36,8 +36,7 @@ func newEmptySecure() *SecureTrie {
func makeTestSecureTrie() (*Database, *SecureTrie, map[string][]byte) {
// Create an empty trie
triedb := NewDatabase(memorydb.New())
trie, _ := NewSecure(common.Hash{}, triedb, 0)
trie, _ := NewSecure(common.Hash{}, triedb)
// Fill it with some arbitrary data
content := make(map[string][]byte)