cmd/compile: merge TPTR32 and TPTR64 as TPTR

Change-Id: I0490098a7235458c5aede1135426a9f19f8584a7
Reviewed-on: https://go-review.googlesource.com/c/76312
Run-TryBot: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
This commit is contained in:
Matthew Dempsky 2017-11-06 14:50:30 -08:00
parent d397d4bffc
commit 62e5215a2a
19 changed files with 45 additions and 79 deletions

View file

@ -347,7 +347,7 @@ func convlit1(n *Node, t *types.Type, explicit bool, reuse canReuseNode) *Node {
case TARRAY:
goto bad
case TPTR32, TPTR64, TUNSAFEPTR:
case TPTR, TUNSAFEPTR:
n.SetVal(Val{new(Mpint)})
case TCHAN, TFUNC, TINTER, TMAP, TSLICE:
@ -1482,7 +1482,7 @@ func smallintconst(n *Node) bool {
TBOOL:
return true
case TIDEAL, TINT64, TUINT64, TPTR32, TPTR64:
case TIDEAL, TINT64, TUINT64, TPTR:
v, ok := n.Val().U.(*Mpint)
if ok && v.Cmp(minintval[TINT32]) > 0 && v.Cmp(maxintval[TINT32]) < 0 {
return true