]> Cypherpunks repositories - gostls13.git/commitdiff
[dev.ssa] cmd/compile: make etypes readable
authorJosh Bleecher Snyder <josharian@gmail.com>
Thu, 23 Jul 2015 02:18:35 +0000 (19:18 -0700)
committerJosh Bleecher Snyder <josharian@gmail.com>
Thu, 23 Jul 2015 18:09:12 +0000 (18:09 +0000)
Change-Id: Id89ea3b458597dd93d269b9fe5475e9cccc6d992
Reviewed-on: https://go-review.googlesource.com/12562
Reviewed-by: Keith Randall <khr@golang.org>
src/cmd/compile/internal/gc/fmt.go
src/cmd/compile/internal/gc/ssa.go

index b40014be80dec993cce8e4dae9198d8ba91c20b6..c50579924d536a20b9efa56e7fbf301b2c6d5184 100644 (file)
@@ -396,6 +396,7 @@ var etnames = []string{
        TFORW:       "FORW",
        TFIELD:      "FIELD",
        TSTRING:     "STRING",
+       TUNSAFEPTR:  "TUNSAFEPTR",
        TANY:        "ANY",
 }
 
index 6871fc48cd552aaaf151c412a1f8f9d492de7d76..d29da9d042f522b90461c419d284b9ef777dee5f 100644 (file)
@@ -790,7 +790,7 @@ func (s *state) ssaOp(op uint8, t *Type) ssa.Op {
        }
        x, ok := opToSSA[opAndType{op, etype}]
        if !ok {
-               s.Unimplementedf("unhandled binary op %s etype=%d", opnames[op], etype)
+               s.Unimplementedf("unhandled binary op %s etype=%s", opnames[op], Econv(int(etype), 0))
        }
        return x
 }