(count, uniqueCount int)
| 234 | } |
| 235 | |
| 236 | func generateRepeatedStrings(count, uniqueCount int) []string { |
| 237 | result := make([]string, count) |
| 238 | for i := 0; i < count; i++ { |
| 239 | result[i] = fmt.Sprintf("value_%d", i%uniqueCount) |
| 240 | } |
| 241 | return result |
| 242 | } |
| 243 | |
| 244 | // Benchmark string interning |
| 245 | func BenchmarkStringInterning(b *testing.B) { |
no outgoing calls
no test coverage detected