• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

lmittmann / w3 / 7640376565

24 Jan 2024 12:46PM UTC coverage: 77.601%. Remained the same
7640376565

Pull #101

github

web-flow
build(deps): bump github.com/ethereum/go-ethereum in /examples

Bumps [github.com/ethereum/go-ethereum](https://github.com/ethereum/go-ethereum) from 1.13.8 to 1.13.11.
- [Release notes](https://github.com/ethereum/go-ethereum/releases)
- [Commits](https://github.com/ethereum/go-ethereum/compare/v1.13.8...v1.13.11)

---
updated-dependencies:
- dependency-name: github.com/ethereum/go-ethereum
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Pull Request #101: build(deps): bump github.com/ethereum/go-ethereum from 1.13.8 to 1.13.11 in /examples

1805 of 2326 relevant lines covered (77.6%)

1420.88 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

8.93
/w3vm/multi_tracer.go
1
package w3vm
2

3
import (
4
        "math/big"
5

6
        "github.com/ethereum/go-ethereum/common"
7
        "github.com/ethereum/go-ethereum/core/vm"
8
)
9

10
// multiEVMLogger is a wrapper for multiple EVMLogger's.
11
type multiEVMLogger []vm.EVMLogger
12

13
func newMultiEVMLogger(tracers []vm.EVMLogger) vm.EVMLogger {
4,980✔
14
        // hot path
4,980✔
15
        switch len(tracers) {
4,980✔
16
        case 0:
4,980✔
17
                return nil
4,980✔
18
        case 1:
×
19
                return tracers[0]
×
20
        }
21

22
        // filter nil tracers
23
        // NOTE: this edits the tracers slice in place.
24
        var j int
×
25
        for i := range tracers {
×
26
                if tracers[i] == nil {
×
27
                        continue
×
28
                } else if i > j {
×
29
                        tracers[j], tracers[i] = tracers[i], tracers[j]
×
30
                }
×
31
                j++
×
32
        }
33
        tracers = tracers[:j]
×
34

×
35
        switch len(tracers) {
×
36
        case 0:
×
37
                return nil
×
38
        case 1:
×
39
                return tracers[0]
×
40
        default:
×
41
                return multiEVMLogger(tracers)
×
42
        }
43
}
44

45
func (m multiEVMLogger) CaptureTxStart(gasLimit uint64) {
×
46
        for _, tracer := range m {
×
47
                tracer.CaptureTxStart(gasLimit)
×
48
        }
×
49
}
50

51
func (m multiEVMLogger) CaptureTxEnd(restGas uint64) {
×
52
        for _, tracer := range m {
×
53
                tracer.CaptureTxEnd(restGas)
×
54
        }
×
55
}
56

57
func (m multiEVMLogger) CaptureStart(env *vm.EVM, from common.Address, to common.Address, create bool, input []byte, gas uint64, value *big.Int) {
×
58
        for _, tracer := range m {
×
59
                tracer.CaptureStart(env, from, to, create, input, gas, value)
×
60
        }
×
61
}
62

63
func (m multiEVMLogger) CaptureEnd(output []byte, gasUsed uint64, err error) {
×
64
        for _, tracer := range m {
×
65
                tracer.CaptureEnd(output, gasUsed, err)
×
66
        }
×
67
}
68

69
func (m multiEVMLogger) CaptureEnter(typ vm.OpCode, from common.Address, to common.Address, input []byte, gas uint64, value *big.Int) {
×
70
        for _, tracer := range m {
×
71
                tracer.CaptureEnter(typ, from, to, input, gas, value)
×
72
        }
×
73
}
74

75
func (m multiEVMLogger) CaptureExit(output []byte, gasUsed uint64, err error) {
×
76
        for _, tracer := range m {
×
77
                tracer.CaptureExit(output, gasUsed, err)
×
78
        }
×
79
}
80

81
func (m multiEVMLogger) CaptureState(pc uint64, op vm.OpCode, gas, cost uint64, scope *vm.ScopeContext, rData []byte, depth int, err error) {
×
82
        for _, tracer := range m {
×
83
                tracer.CaptureState(pc, op, gas, cost, scope, rData, depth, err)
×
84
        }
×
85
}
86

87
func (m multiEVMLogger) CaptureFault(pc uint64, op vm.OpCode, gas, cost uint64, scope *vm.ScopeContext, depth int, err error) {
×
88
        for _, tracer := range m {
×
89
                tracer.CaptureFault(pc, op, gas, cost, scope, depth, err)
×
90
        }
×
91
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc