diff --git a/core/state/state_object.go b/core/state/state_object.go index 0af0fbd5ab..fa67c94e4c 100644 --- a/core/state/state_object.go +++ b/core/state/state_object.go @@ -87,10 +87,6 @@ type StateObject struct { dirty bool } -func (self *StateObject) Reset() { - self.storage = make(Storage) -} - func NewStateObject(address common.Address, db common.Database) *StateObject { object := &StateObject{db: db, address: address, balance: new(big.Int), gasPool: new(big.Int), dirty: true} object.trie = trie.NewSecure((common.Hash{}).Bytes(), db) diff --git a/core/state/statedb.go b/core/state/statedb.go index 577f7162eb..468b2dfe48 100644 --- a/core/state/statedb.go +++ b/core/state/statedb.go @@ -315,18 +315,6 @@ func (s *StateDB) Trie() *trie.SecureTrie { return s.trie } -// Resets the trie and all siblings -func (s *StateDB) Reset() { - s.trie.Reset() - - // Reset all nested states - for _, stateObject := range s.stateObjects { - stateObject.Reset() - } - - s.Empty() -} - // Syncs the trie and all siblings func (s *StateDB) Sync() { // Sync all nested states diff --git a/core/types/transaction.go b/core/types/transaction.go index 28a7e02b31..8260d74230 100644 --- a/core/types/transaction.go +++ b/core/types/transaction.go @@ -33,10 +33,6 @@ import ( var ErrInvalidSig = errors.New("invalid v, r, s values") -func IsContractAddr(addr []byte) bool { - return len(addr) == 0 -} - type Transaction struct { data txdata // caches