cmd/internal/gc: delete Strlit, Zconv
Strlit was just a poor excuse for a Go string.
Use a Go string.
In the one case where it was a string-or-nil (Type.Note), use a *string.
Zconv was a poor excuse for %q. Use %q.
The only important part about Zconv's implementation
was that the compiler and linker agreed on the quoting rules.
Now they both use %q instead of having two Zconvs.
This CL *does* change the generated object files, because the
quoted strings end up in symbol names.
For example the string "\r\n" used to be named go.string."\r\n"
and is now go.string."\x0d\n".
Change-Id: I5c0d38e1570ffc495f0db1a20273c9564104a7e8
Reviewed-on: https://go-review.googlesource.com/6519
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Rob Pike <r@golang.org>
diff --git a/src/cmd/internal/gc/closure.go b/src/cmd/internal/gc/closure.go
index 8f13a3e..c9b6981 100644
--- a/src/cmd/internal/gc/closure.go
+++ b/src/cmd/internal/gc/closure.go
@@ -532,7 +532,7 @@
}
if spkg == nil {
if makepartialcall_gopkg == nil {
- makepartialcall_gopkg = mkpkg(newstrlit("go"))
+ makepartialcall_gopkg = mkpkg("go")
}
spkg = makepartialcall_gopkg
}