clean up
This commit is contained in:
parent
49f3d43e46
commit
a5a95c2a9f
@ -154,9 +154,6 @@ func (s *stateObject) GetCommittedState(db StateDatabase, key common.Hash) commo
|
|||||||
return s.fakeStorage[key]
|
return s.fakeStorage[key]
|
||||||
}
|
}
|
||||||
// If we have a pending write or clean cached, return that
|
// If we have a pending write or clean cached, return that
|
||||||
if value, pending := s.pendingStorage[key]; pending {
|
|
||||||
return value
|
|
||||||
}
|
|
||||||
if value, cached := s.originStorage[key]; cached {
|
if value, cached := s.originStorage[key]; cached {
|
||||||
return value
|
return value
|
||||||
}
|
}
|
||||||
|
29
statedb.go
29
statedb.go
@ -15,23 +15,20 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
/*
|
/*
|
||||||
The portions of the EVM we want to leverage only use the following methods:
|
The portions of the EVM we want to leverage only use the following methods
|
||||||
|
(The rest can be left with panics for now):
|
||||||
|
|
||||||
GetBalance
|
* Exist
|
||||||
Snapshot
|
* CreateAccount
|
||||||
Exist
|
* GetCodeHash
|
||||||
CreateAccount
|
* AddAddressToAccessList
|
||||||
SubBalance
|
* {Get,Set}Nonce
|
||||||
AddBalance
|
* {Get,Set,Add,Sub}Balance
|
||||||
GetCode
|
* {Get,Set}Code
|
||||||
GetCodeHash
|
* {Get,Set}State
|
||||||
RevertToSnapshot
|
* {Get,Set}TransientState
|
||||||
GetNonce
|
* Snapshot
|
||||||
SetNonce
|
* RevertToSnapshot
|
||||||
AddAddressToAccessList
|
|
||||||
SetCode
|
|
||||||
|
|
||||||
The rest can be left with panics for now
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
var _ vm.StateDB = &StateDB{}
|
var _ vm.StateDB = &StateDB{}
|
||||||
|
Loading…
Reference in New Issue
Block a user