core/state: simplify proof methods (#17965)

This fixes the import cycle build error in core/vm tests.
There is no need to refer to core/vm for a type definition.
This commit is contained in:
Felix Lange
2018-10-23 21:51:41 +02:00
committed by Martin Holst Swende
parent 4c0883e20d
commit 7f22b59f87
2 changed files with 13 additions and 17 deletions

View File

@ -35,8 +35,6 @@ type StateDB interface {
SetNonce(common.Address, uint64)
GetCodeHash(common.Address) common.Hash
GetProof(common.Address) (ProofList, error)
GetStorageProof(common.Address, common.Hash) (ProofList, error)
GetCode(common.Address) []byte
SetCode(common.Address, []byte)
GetCodeSize(common.Address) int
@ -80,11 +78,3 @@ type CallContext interface {
// Create a new contract
Create(env *EVM, me ContractRef, data []byte, gas, value *big.Int) ([]byte, common.Address, error)
}
// MerkleProof
type ProofList [][]byte
func (n *ProofList) Put(key []byte, value []byte) error {
*n = append(*n, value)
return nil
}