mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-23 13:16:42 +00:00
fix most of the failing 7702 tests with note about how to properly fix this in the tracer hook calling code
This commit is contained in:
parent
98451ebec9
commit
ff27bb0748
1 changed files with 5 additions and 1 deletions
|
|
@ -107,7 +107,11 @@ func (a *BlockAccessListTracer) OnExit(depth int, output []byte, gasUsed uint64,
|
||||||
}
|
}
|
||||||
|
|
||||||
func (a *BlockAccessListTracer) OnCodeChange(addr common.Address, prevCodeHash common.Hash, prevCode []byte, codeHash common.Hash, code []byte, reason tracing.CodeChangeReason) {
|
func (a *BlockAccessListTracer) OnCodeChange(addr common.Address, prevCodeHash common.Hash, prevCode []byte, codeHash common.Hash, code []byte, reason tracing.CodeChangeReason) {
|
||||||
a.accessListBuilder.CodeChange(addr, prevCode, code)
|
// TODO: if we don't have this equality check, some tests fail. should be investigated.
|
||||||
|
// probably the tracer shouldn't invoke code change if the code didn't actually change tho.
|
||||||
|
if prevCodeHash != codeHash {
|
||||||
|
a.accessListBuilder.CodeChange(addr, prevCode, code)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (a *BlockAccessListTracer) OnSelfDestruct(addr common.Address) {
|
func (a *BlockAccessListTracer) OnSelfDestruct(addr common.Address) {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue