summaryrefslogtreecommitdiff
path: root/parse
diff options
context:
space:
mode:
authorOri Bernstein <ori@eigenstate.org>2017-09-22 03:48:56 -0700
committerOri Bernstein <ori@eigenstate.org>2017-09-22 10:56:13 -0700
commit0de1c881850c5fec2183b2e59cd10b8931cd93a4 (patch)
treed7b22330b3534140e9c1d15ff5d68e77fc384a2a /parse
parent097d0aa9c3b22ed55d82bf4c0bab716942357ad6 (diff)
downloadmc-0de1c881850c5fec2183b2e59cd10b8931cd93a4.tar.gz
Remove 'in' token.
It's now available as a variable name.
Diffstat (limited to 'parse')
-rw-r--r--parse/gram.y5
-rw-r--r--parse/tok.c1
2 files changed, 0 insertions, 6 deletions
diff --git a/parse/gram.y b/parse/gram.y
index f96cea6..08e50a2 100644
--- a/parse/gram.y
+++ b/parse/gram.y
@@ -84,7 +84,6 @@ static void setupinit(Node *n);
%token<tok> Ttype /* type */
%token<tok> Tfor /* for */
-%token<tok> Tin /* in */
%token<tok> Twhile /* while */
%token<tok> Tif /* if */
%token<tok> Telse /* else */
@@ -946,10 +945,6 @@ continue : Tcontinue
forstmt : Tfor optexprln loopcond optexprln block
{$$ = mkloopstmt($1->loc, $2, $3, $4, $5);}
- | Tfor expr Tin exprln block {
- $$ = mkiterstmt($1->loc, $2, $4, $5);
- fprintf(stderr, "%s:%d: deprecated for syntax. use ':' to replace 'in'\n", fname($1->loc), lnum($1->loc));
- }
| Tfor expr Tcolon exprln block
{$$ = mkiterstmt($1->loc, $2, $4, $5);}
| Tfor decl Tendln loopcond optexprln block {
diff --git a/parse/tok.c b/parse/tok.c
index 119d637..eb5ba1c 100644
--- a/parse/tok.c
+++ b/parse/tok.c
@@ -191,7 +191,6 @@ kwd(char *s)
{"goto", Tgoto},
{"if", Tif},
{"impl", Timpl},
- {"in", Tin},
{"match", Tmatch},
{"pkg", Tpkg},
{"pkglocal", Tattr},