Commit a665e292 authored by Ken Thompson's avatar Ken Thompson

bug with select :=

R=r
OCL=25278
CL=25278
parent 82c38cf8
...@@ -343,7 +343,6 @@ loop: ...@@ -343,7 +343,6 @@ loop:
case OSELECT: case OSELECT:
if(top != Etop) if(top != Etop)
goto nottop; goto nottop;
walkselect(n); walkselect(n);
goto ret; goto ret;
...@@ -1487,6 +1486,7 @@ selectas(Node *name, Node *expr) ...@@ -1487,6 +1486,7 @@ selectas(Node *name, Node *expr)
if(expr == N || expr->op != ORECV) if(expr == N || expr->op != ORECV)
goto bad; goto bad;
walktype(expr->left, Erv);
t = expr->left->type; t = expr->left->type;
if(t == T) if(t == T)
goto bad; goto bad;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment