We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 601ea3a commit 1e05849Copy full SHA for 1e05849
staging/src/k8s.io/apimachinery/pkg/util/sets/set_test.go
@@ -420,5 +420,23 @@ func BenchmarkStringSet(b *testing.B) {
420
randOperand().List()
421
}
422
})
423
+ b.Run(fmt.Sprintf("difference-%v", here.size), func(b *testing.B) {
424
+ b.ReportAllocs()
425
+ for b.Loop() {
426
+ for item := range randOperand().Difference(randOperand()) {
427
+ _ = item
428
+ }
429
430
+ })
431
+ b.Run(fmt.Sprintf("difference-seq-%v", here.size), func(b *testing.B) {
432
433
434
+ s1 := Set[string](randOperand())
435
+ s2 := Set[string](randOperand())
436
+ for item := range s1.DifferenceSeq(s2) {
437
438
439
440
441
442
0 commit comments