1
0
mirror of https://github.com/golang/go synced 2024-11-11 20:50:23 -07:00

gc: fix crash on complicated arg to make slice.

Fixes #615.

R=ken2
CC=golang-dev
https://golang.org/cl/255043
This commit is contained in:
Russ Cox 2010-03-05 19:29:14 -08:00
parent 067fe2840b
commit a9b9afa930

View File

@ -1078,7 +1078,7 @@ walkexpr(Node **np, NodeList **init)
t = n->type;
fn = syslook("makeslice", 1);
argtype(fn, t->type); // any-1
n = mkcall1(fn, n->type, nil,
n = mkcall1(fn, n->type, init,
typename(n->type),
conv(n->left, types[TINT]),
conv(n->right, types[TINT]));