- Sort Score
- Result 10 results
- Languages All
Results 1 - 1 of 1 for BenchmarkCompareBytesEmpty (0.12 sec)
-
src/bytes/compare_test.go
b1 := []byte("Hello Gophers!") var b2 []byte for i := 0; i < b.N; i++ { if Compare(b1, b2) != 1 { b.Fatal("b1 > b2 failed") } } } func BenchmarkCompareBytesEmpty(b *testing.B) { b1 := []byte("") b2 := b1 for i := 0; i < b.N; i++ { if Compare(b1, b2) != 0 { b.Fatal("b1 != b2") } } } func BenchmarkCompareBytesIdentical(b *testing.B) {
Registered: Tue Nov 05 11:13:11 UTC 2024 - Last Modified: Thu Jul 13 23:11:42 UTC 2023 - 6.8K bytes - Viewed (0)