core, all: split vm.Context into BlockContext and TxContext (#21672)

* all: core: split vm.Config into BlockConfig and TxConfig

* core: core/vm: reset EVM between tx in block instead of creating new

* core/vm: added docs
This commit is contained in:
Marius van der Wijden
2020-11-13 13:42:19 +01:00
committed by GitHub
parent 6f4cccf8d2
commit 2045a2bba3
24 changed files with 183 additions and 139 deletions

View File

@ -545,7 +545,7 @@ func (jst *Tracer) CaptureState(env *vm.EVM, pc uint64, op vm.OpCode, gas, cost
if jst.err == nil {
// Initialize the context if it wasn't done yet
if !jst.inited {
jst.ctx["block"] = env.BlockNumber.Uint64()
jst.ctx["block"] = env.Context.BlockNumber.Uint64()
jst.inited = true
}
// If tracing was interrupted, set the error and stop