cmd/internal/gc, cmd/internal/obj: remove pointless fmt.Sprintf calls
This is a follow-up to CL 6265. No behavior changes.
The diff was generated with eg, using template:
package p
import "fmt"
func before(a string) string { return fmt.Sprintf(a) }
func after(a string) string { return a }
Change-Id: I7b3bebf31be5cd1ae2233da06cb4502a3d73f092
Reviewed-on: https://go-review.googlesource.com/6269
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
diff --git a/src/cmd/internal/gc/subr.go b/src/cmd/internal/gc/subr.go
index 998b3e7..1c59e59 100644
--- a/src/cmd/internal/gc/subr.go
+++ b/src/cmd/internal/gc/subr.go
@@ -1729,9 +1729,9 @@
// common mistake: *struct and *interface.
if tl != nil && tr != nil && Isptr[tl.Etype] != 0 && Isptr[tr.Etype] != 0 {
if tl.Type.Etype == TSTRUCT && tr.Type.Etype == TINTER {
- fmt_ += fmt.Sprintf("\n\t(*struct vs *interface)")
+ fmt_ += "\n\t(*struct vs *interface)"
} else if tl.Type.Etype == TINTER && tr.Type.Etype == TSTRUCT {
- fmt_ += fmt.Sprintf("\n\t(*interface vs *struct)")
+ fmt_ += "\n\t(*interface vs *struct)"
}
}