cmd/internal/gc: convert yet more Node fields to bools
Convert Embedded, Method, and Colas to bools.
I believe that this is the last of the Node fields
that can be trivially converted to bools.
No functional changes. Passes toolstash -cmp.
Change-Id: I81962ee47866596341fc60d24d6959c20cd7fc1c
Reviewed-on: https://go-review.googlesource.com/8440
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
diff --git a/src/cmd/internal/gc/gsubr.go b/src/cmd/internal/gc/gsubr.go
index d54f905..6ca8c75 100644
--- a/src/cmd/internal/gc/gsubr.go
+++ b/src/cmd/internal/gc/gsubr.go
@@ -133,7 +133,7 @@
*n = Node{}
n.Op = OREGISTER
- n.Addable = 1
+ n.Addable = true
ullmancalc(n)
n.Val.U.Reg = int16(r)
n.Type = t
@@ -361,7 +361,7 @@
if s == nil {
s = Lookup(".noname")
}
- if n.Method != 0 {
+ if n.Method {
if n.Type != nil {
if n.Type.Sym != nil {
if n.Type.Sym.Pkg != nil {
@@ -520,7 +520,7 @@
Fatal("nodarg: offset not computed for %v", Tconv(t, 0))
}
n.Xoffset = first.Width
- n.Addable = 1
+ n.Addable = true
goto fp
}
@@ -546,7 +546,7 @@
Fatal("nodarg: offset not computed for %v", Tconv(t, 0))
}
n.Xoffset = t.Width
- n.Addable = 1
+ n.Addable = true
n.Orig = t.Nname
// Rewrite argument named _ to __,