mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
cmd/internal/gc: make Node.Needzero a bool
Node.Needzero only has two values and acts as a bool, so make it a bool. Change-Id: Ica46e5ebafbe478017ea52ce6bb335f404059677 Reviewed-on: https://go-review.googlesource.com/6800 Reviewed-by: Ian Lance Taylor <iant@golang.org> Run-TryBot: Dave Cheney <dave@cheney.net> TryBot-Result: Gobot Gobot <gobot@golang.org>
This commit is contained in:
parent
f09887cdce
commit
38a61ff41f
7 changed files with 9 additions and 9 deletions
|
|
@ -211,8 +211,8 @@ func cmpstackvar(a *Node, b *Node) int {
|
|||
return bp - ap
|
||||
}
|
||||
|
||||
ap = int(a.Needzero)
|
||||
bp = int(b.Needzero)
|
||||
ap = bool2int(a.Needzero)
|
||||
bp = bool2int(b.Needzero)
|
||||
if ap != bp {
|
||||
return bp - ap
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue