Commit 5e157db3 authored by Josh Bleecher Snyder's avatar Josh Bleecher Snyder

cmd/compile: make Class a Stringer

Change-Id: I7fd137d01ab5a0690773ca6e47d2bd796f0e393e
Reviewed-on: https://go-review.googlesource.com/42177
Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com>
Reviewed-by: default avatarBrad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
parent a8e3852a
// Code generated by "stringer -type=Class"; DO NOT EDIT.
package gc
import "fmt"
const _Class_name = "PxxxPEXTERNPAUTOPAUTOHEAPPPARAMPPARAMOUTPFUNCPDISCARD"
var _Class_index = [...]uint8{0, 4, 11, 16, 25, 31, 40, 45, 53}
func (i Class) String() string {
if i >= Class(len(_Class_index)-1) {
return fmt.Sprintf("Class(%d)", i)
}
return _Class_name[_Class_index[i]:_Class_index[i+1]]
}
......@@ -31,6 +31,7 @@ func isRuntimePkg(p *types.Pkg) bool {
// called declaration contexts.
type Class uint8
//go:generate stringer -type=Class
const (
Pxxx Class = iota // no class; used during ssa conversion to indicate pseudo-variables
PEXTERN // global variable
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment