mirror of
https://github.com/golang/go
synced 2024-11-02 11:50:30 +00:00
cmd/compile: add EType.String and missing EType names
Passes toolstash -cmp. Change-Id: Icc387eb557d5029e903923a051b565812fd2246b Reviewed-on: https://go-review.googlesource.com/21234 Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com> Reviewed-by: Matthew Dempsky <mdempsky@google.com>
This commit is contained in:
parent
0f86d1edfb
commit
cabf73ffb8
1 changed files with 12 additions and 0 deletions
|
@ -394,6 +394,7 @@ s%^ ........*\]%&~%g
|
|||
s%~ %%g
|
||||
*/
|
||||
var etnames = []string{
|
||||
Txxx: "Txxx",
|
||||
TINT: "INT",
|
||||
TUINT: "UINT",
|
||||
TINT8: "INT8",
|
||||
|
@ -422,6 +423,13 @@ var etnames = []string{
|
|||
TSTRING: "STRING",
|
||||
TUNSAFEPTR: "TUNSAFEPTR",
|
||||
TANY: "ANY",
|
||||
TIDEAL: "TIDEAL",
|
||||
TNIL: "TNIL",
|
||||
TBLANK: "TBLANK",
|
||||
TFUNCARGS: "TFUNCARGS",
|
||||
TCHANARGS: "TCHANARGS",
|
||||
TINTERMETH: "TINTERMETH",
|
||||
TDDDFIELD: "TDDDFIELD",
|
||||
}
|
||||
|
||||
// Fmt "%E": etype
|
||||
|
@ -432,6 +440,10 @@ func Econv(et EType) string {
|
|||
return fmt.Sprintf("E-%d", et)
|
||||
}
|
||||
|
||||
func (e EType) String() string {
|
||||
return Econv(e)
|
||||
}
|
||||
|
||||
// Fmt "%S": syms
|
||||
func symfmt(s *Sym, flag FmtFlag) string {
|
||||
if s.Pkg != nil && flag&FmtShort == 0 {
|
||||
|
|
Loading…
Reference in a new issue