mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
cmd/compile: minor cleanup in mapinit
Change-Id: I7d58d200f7e8b2c0a6e35371da0dafd9b44e9057 Reviewed-on: https://go-review.googlesource.com/26757 Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com> Reviewed-by: David Crawshaw <crawshaw@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This commit is contained in:
parent
41943d9639
commit
5bddca64a8
1 changed files with 5 additions and 4 deletions
|
|
@ -974,13 +974,14 @@ func maplit(ctxt int, n *Node, m *Node, init *Nodes) {
|
|||
val = temp(m.Type.Val())
|
||||
}
|
||||
|
||||
setlineno(r.Left)
|
||||
a = Nod(OAS, key, r.Left)
|
||||
setlineno(index)
|
||||
a = Nod(OAS, key, index)
|
||||
a = typecheck(a, Etop)
|
||||
a = walkstmt(a)
|
||||
init.Append(a)
|
||||
setlineno(r.Right)
|
||||
a = Nod(OAS, val, r.Right)
|
||||
|
||||
setlineno(value)
|
||||
a = Nod(OAS, val, value)
|
||||
a = typecheck(a, Etop)
|
||||
a = walkstmt(a)
|
||||
init.Append(a)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue