MCPcopy Create free account
hub / github.com/google/pprof / getFlag

Function getFlag

browsertests/testutils.go:184–190  ·  view source on GitHub ↗
(flags testFlags, name string, def T)

Source from the content-addressed store, hash-verified

182var _ driver.FlagSet = testFlags{}
183
184func getFlag[T any](flags testFlags, name string, def T) *T {
185 result := &def
186 if v, ok := flags[name]; ok {
187 *result = v.(T)
188 }
189 return result
190}
191
192type testUI struct {
193 T testing.TB

Callers 5

BoolMethod · 0.85
IntMethod · 0.85
Float64Method · 0.85
StringMethod · 0.85
StringListMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…