aboutsummaryrefslogtreecommitdiffstats
path: root/prog
diff options
context:
space:
mode:
authorDmitry Vyukov <dvyukov@google.com>2024-11-19 16:42:32 +0100
committerDmitry Vyukov <dvyukov@google.com>2024-11-20 11:33:58 +0000
commitf56b4dcc82d7af38bf94d643c5750cf49a91a297 (patch)
tree19b2ea6bfcbf61ab7287d420f39c45432bd9b4cc /prog
parent7d02db5adbb376babbbd3199f8c530e468292727 (diff)
pkg/manager: show number of times coverage for each call has overflowed
If the overflows happen often, it's bad. Add visibility into this.
Diffstat (limited to 'prog')
-rw-r--r--prog/prog.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/prog/prog.go b/prog/prog.go
index de3d87778..ec899e35f 100644
--- a/prog/prog.go
+++ b/prog/prog.go
@@ -17,12 +17,14 @@ type Prog struct {
isUnsafe bool
}
+const ExtraCallName = ".extra"
+
func (p *Prog) CallName(call int) string {
if call >= len(p.Calls) || call < -1 {
panic(fmt.Sprintf("bad call index %v/%v", call, len(p.Calls)))
}
if call == -1 {
- return ".extra"
+ return ExtraCallName
}
return p.Calls[call].Meta.Name
}