1
0
mirror of https://github.com/golang/go synced 2024-11-25 15:57:57 -07:00
R=ken
OCL=21565
CL=21565
This commit is contained in:
Russ Cox 2008-12-18 21:11:56 -08:00
parent 4026500d18
commit 92f74ca7e2
2 changed files with 7 additions and 5 deletions

View File

@ -440,7 +440,7 @@ aindex(Node *b, Type *t)
r = typ(TARRAY);
r->type = t;
r->bound = bound;
dowidth(r);
checkwidth(r);
return r;
}

View File

@ -1995,6 +1995,7 @@ newcompat(Node *n)
if(t == T)
goto bad;
/*
if(isptr[t->etype]) {
if(t->type == T)
goto bad;
@ -2012,12 +2013,13 @@ newcompat(Node *n)
r->type = n->type;
goto ret;
}
*/
switch(t->etype) {
default:
goto bad;
case TSTRUCT:
// goto bad;
//
// case TSTRUCT:
if(n->left != N)
yyerror("dont know what new(,e) means");
@ -3510,7 +3512,7 @@ maplit(Node *n)
tempname(var, t);
a = nod(ONEW, N, N);
a->type = t;
a->type = t->type;
a = nod(OAS, var, a);
addtop = list(addtop, a);