Change-Id: I2d8efef333f2441da6742e125e23ff57c9853ebd
Reviewed-on: https://go-review.googlesource.com/20078
Run-TryBot: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dave Cheney <dave@cheney.net>
}
ct := consttype(n)
- var et int
+ var et EType
if ct < 0 {
goto bad
}
- et = int(t.Etype)
+ et = t.Etype
if et == TINTER {
if ct == CTNIL && n.Type == Types[TNIL] {
n.Type = t
}
case CTSTR, CTBOOL:
- if et != int(n.Type.Etype) {
+ if et != n.Type.Etype {
goto bad
}
if consttype(nl) < 0 {
return
}
- wl := int(nl.Type.Etype)
+ wl := nl.Type.Etype
if Isint[wl] || Isfloat[wl] || Iscomplex[wl] {
wl = TIDEAL
}
nr := n.Right
var rv Val
var lno int
- var wr int
+ var wr EType
var v Val
var norig *Node
var nn *Node
case OCOM_ | CTINT_,
OCOM_ | CTRUNE_:
- et := Txxx
+ var et EType = Txxx
if nl.Type != nil {
- et = int(nl.Type.Etype)
+ et = nl.Type.Etype
}
// calculate the mask in b
if consttype(nr) < 0 {
return
}
- wr = int(nr.Type.Etype)
+ wr = nr.Type.Etype
if Isint[wr] || Isfloat[wr] || Iscomplex[wr] {
wr = TIDEAL
}