x/tools/gopls/internal/analysis/modernize: after refactoring the code using the fmtappendf
analyzer, performance may decrease
#73666
Labels
gopls
Issues related to the Go language server, gopls.
ToolProposal
Issues describing a requested change to a Go tool or command-line program.
Tools
This label describes issues relating to any tools in the x/tools repository.
Milestone
Go version
go1.24.2
Output of
go env
in your module/workspace:What did you do?
benchmark_test.go:
What did you see happen?
go test -bench=. -benchmem -count=5
The result is:
What did you expect to see?
Using fmt.Appendf seems to cause a slight performance decrease. Should we refactor it to use the BenchmarkAppendLiteral style, which has excellent performance?
The text was updated successfully, but these errors were encountered: