MCPcopy
hub / github.com/uber-go/zap / BenchmarkBoolsReflect

Function BenchmarkBoolsReflect

array_test.go:46–53  ·  view source on GitHub ↗
(b *testing.B)

Source from the content-addressed store, hash-verified

44}
45
46func BenchmarkBoolsReflect(b *testing.B) {
47 bs := make([]bool, 50)
48 enc := zapcore.NewJSONEncoder(zapcore.EncoderConfig{})
49 b.ResetTimer()
50 for i := 0; i < b.N; i++ {
51 Reflect("array", bs).AddTo(enc.Clone())
52 }
53}
54
55func TestArrayWrappers(t *testing.T) {
56 tests := []struct {

Callers

nothing calls this directly

Calls 4

NewJSONEncoderFunction · 0.92
ReflectFunction · 0.85
AddToMethod · 0.80
CloneMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…