Passes go build -a -toolexec 'toolstash -cmp' std cmd
Change-Id: Ief4613cfb341172a85e3a894f44fb2bb308c7b55
Reviewed-on: https://go-review.googlesource.com/14554
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dave Cheney <dave@cheney.net>
Embedlineno int32 // first use of TFORW as embedded type
// for TFORW, where to copy the eventual value to
- Copyto *NodeList
+ Copyto []*Node
Lastfn *Node // for usefield
}
func copytype(n *Node, t *Type) {
if t.Etype == TFORW {
// This type isn't computed yet; when it is, update n.
- t.Copyto = list(t.Copyto, n)
+ t.Copyto = append(t.Copyto, n)
return
}
t.Copyto = nil
// Update nodes waiting on this type.
- for ; l != nil; l = l.Next {
- copytype(l.N, t)
+ for _, n := range l {
+ copytype(n, t)
}
// Double-check use of type as embedded type.