From: Ken Thompson Date: Fri, 19 Dec 2008 06:01:46 +0000 (-0800) Subject: bug in [const] X-Git-Tag: weekly.2009-11-06~2480 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=c9954c63a8f4f19be93dfaaaff8ca5afa65f25b5;p=gostls13.git bug in [const] R=r OCL=21569 CL=21569 --- diff --git a/src/cmd/6g/cgen.c b/src/cmd/6g/cgen.c index a56ba72236..bb5cb24612 100644 --- a/src/cmd/6g/cgen.c +++ b/src/cmd/6g/cgen.c @@ -485,7 +485,7 @@ agen(Node *n, Node *res) // constant index if(whatis(nr) == Wlitint) { v = mpgetfix(nr->val.u.xval); - if(isptrdarray(nl->type)) { + if(isdarray(nl->type)) { if(!debug['B']) { n1 = n3; @@ -536,7 +536,7 @@ agen(Node *n, Node *res) if(!debug['B']) { // check bounds - if(isptrdarray(nl->type)) { + if(isdarray(nl->type)) { n1 = n3; n1.op = OINDREG; n1.type = types[tptr]; @@ -552,7 +552,7 @@ agen(Node *n, Node *res) patch(p1, pc); } - if(isptrdarray(nl->type)) { + if(isdarray(nl->type)) { n1 = n3; n1.op = OINDREG; n1.type = types[tptr];