MCPcopy
hub / github.com/expr-lang/expr / countingPatcher

Struct countingPatcher

test/patch/patch_count_test.go:15–17  ·  view source on GitHub ↗

This patcher tracks how many nodes it patches which can be used to verify if it was run too many times or not at all

Source from the content-addressed store, hash-verified

13// This patcher tracks how many nodes it patches which can
14// be used to verify if it was run too many times or not at all
15type countingPatcher struct {
16 PatchCount int
17}
18
19func (c *countingPatcher) Visit(node *ast.Node) {
20 switch (*node).(type) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected