- Sort Score
- Result 10 results
- Languages All
Results 1 - 1 of 1 for TestNonEscapingMap (0.18 sec)
-
src/runtime/map_test.go
func BenchmarkMapPop1000(b *testing.B) { benchmarkMapPop(b, 1000) } func BenchmarkMapPop10000(b *testing.B) { benchmarkMapPop(b, 10000) } var testNonEscapingMapVariable int = 8 func TestNonEscapingMap(t *testing.T) { n := testing.AllocsPerRun(1000, func() { m := map[int]int{} m[0] = 0 }) if n != 0 { t.Fatalf("mapliteral: want 0 allocs, got %v", n) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:00:11 UTC 2024 - 33.5K bytes - Viewed (0)