1
0
mirror of https://github.com/golang/go synced 2024-11-17 21:04:43 -07:00

cmd/gc: delete old map delete in walk

R=ken2
CC=golang-dev
https://golang.org/cl/5783047
This commit is contained in:
Russ Cox 2012-03-07 22:03:35 -05:00
parent b0996334c1
commit 9069721b0e

View File

@ -646,12 +646,6 @@ walkexpr(Node **np, NodeList **init)
n->ninit = nil;
l = n->list->n;
r = n->list->next->n;
if(n->right != N) {
// TODO: Remove once two-element map assigment is gone.
l = safeexpr(l, init);
r = safeexpr(r, init);
safeexpr(n->right, init); // cause side effects from n->right
}
t = l->type;
n = mkcall1(mapfndel("mapdelete", t), t->down, init, typename(t), l, r);
goto ret;