core/vm: move Log to core/types
This significantly reduces the dependency closure of ethclient, which no longer depends on core/vm as of this change. All uses of vm.Logs are replaced by []*types.Log. NewLog is gone too, the constructor simply returned a literal.
This commit is contained in:
@ -883,7 +883,7 @@ func (self *BlockChain) InsertChain(chain types.Blocks) (int, error) {
|
||||
var (
|
||||
stats = insertStats{startTime: time.Now()}
|
||||
events = make([]interface{}, 0, len(chain))
|
||||
coalescedLogs vm.Logs
|
||||
coalescedLogs []*types.Log
|
||||
nonceChecked = make([]bool, len(chain))
|
||||
)
|
||||
|
||||
@ -1094,7 +1094,7 @@ func (self *BlockChain) reorg(oldBlock, newBlock *types.Block) error {
|
||||
oldStart = oldBlock
|
||||
newStart = newBlock
|
||||
deletedTxs types.Transactions
|
||||
deletedLogs vm.Logs
|
||||
deletedLogs []*types.Log
|
||||
// collectLogs collects the logs that were generated during the
|
||||
// processing of the block that corresponds with the given hash.
|
||||
// These logs are later announced as deleted.
|
||||
@ -1210,7 +1210,7 @@ func (self *BlockChain) reorg(oldBlock, newBlock *types.Block) error {
|
||||
|
||||
// postChainEvents iterates over the events generated by a chain insertion and
|
||||
// posts them into the event mux.
|
||||
func (self *BlockChain) postChainEvents(events []interface{}, logs vm.Logs) {
|
||||
func (self *BlockChain) postChainEvents(events []interface{}, logs []*types.Log) {
|
||||
// post event logs for further processing
|
||||
self.eventMux.Post(logs)
|
||||
for _, event := range events {
|
||||
|
Reference in New Issue
Block a user