diff options
| author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2000-01-10 15:34:38 -0200 |
|---|---|---|
| committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2000-01-10 15:34:38 -0200 |
| commit | dcb7bb514e1d1e3ee0f56b380cb1cbb45f52b304 (patch) | |
| tree | 50d40788db610da05f3ec8e2ebb237766b2a4582 /lparser.c | |
| parent | b3aaa048b05e62d14431f1f45d17856df47a88ae (diff) | |
| download | lua-dcb7bb514e1d1e3ee0f56b380cb1cbb45f52b304.tar.gz lua-dcb7bb514e1d1e3ee0f56b380cb1cbb45f52b304.tar.bz2 lua-dcb7bb514e1d1e3ee0f56b380cb1cbb45f52b304.zip | |
details (error messages)
Diffstat (limited to '')
| -rw-r--r-- | lparser.c | 10 |
1 files changed, 5 insertions, 5 deletions
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | ** $Id: lparser.c,v 1.51 1999/12/29 16:31:15 roberto Exp roberto $ | 2 | ** $Id: lparser.c,v 1.52 1999/12/29 18:07:10 roberto Exp roberto $ |
| 3 | ** LL(1) Parser and code generator for Lua | 3 | ** LL(1) Parser and code generator for Lua |
| 4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
| 5 | */ | 5 | */ |
| @@ -674,7 +674,7 @@ static void check_match (LexState *ls, int what, int who, int where) { | |||
| 674 | static int checkname (LexState *ls) { | 674 | static int checkname (LexState *ls) { |
| 675 | int sc; | 675 | int sc; |
| 676 | if (ls->token != NAME) | 676 | if (ls->token != NAME) |
| 677 | luaX_error(ls, "`NAME' expected"); | 677 | luaX_error(ls, "<name> expected"); |
| 678 | sc = string_constant(ls, ls->fs, ls->seminfo.ts); | 678 | sc = string_constant(ls, ls->fs, ls->seminfo.ts); |
| 679 | next(ls); | 679 | next(ls); |
| 680 | return sc; | 680 | return sc; |
| @@ -884,7 +884,7 @@ static void recfield (LexState *ls) { | |||
| 884 | check(ls, ']'); | 884 | check(ls, ']'); |
| 885 | break; | 885 | break; |
| 886 | 886 | ||
| 887 | default: luaX_error(ls, "NAME or `[' expected"); | 887 | default: luaX_error(ls, "<name> or `[' expected"); |
| 888 | } | 888 | } |
| 889 | check(ls, '='); | 889 | check(ls, '='); |
| 890 | exp1(ls); | 890 | exp1(ls); |
| @@ -1423,14 +1423,14 @@ static void parlist (LexState *ls) { | |||
| 1423 | case NAME: /* tailparlist -> NAME [',' tailparlist] */ | 1423 | case NAME: /* tailparlist -> NAME [',' tailparlist] */ |
| 1424 | goto init; | 1424 | goto init; |
| 1425 | 1425 | ||
| 1426 | default: luaX_error(ls, "NAME or `...' expected"); | 1426 | default: luaX_error(ls, "<name> or `...' expected"); |
| 1427 | } | 1427 | } |
| 1428 | } | 1428 | } |
| 1429 | break; | 1429 | break; |
| 1430 | 1430 | ||
| 1431 | case ')': break; /* parlist -> empty */ | 1431 | case ')': break; /* parlist -> empty */ |
| 1432 | 1432 | ||
| 1433 | default: luaX_error(ls, "NAME or `...' expected"); | 1433 | default: luaX_error(ls, "<name> or `...' expected"); |
| 1434 | } | 1434 | } |
| 1435 | code_args(ls, nparams, dots); | 1435 | code_args(ls, nparams, dots); |
| 1436 | } | 1436 | } |
