diff options
| author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 1999-07-22 16:29:42 -0300 |
|---|---|---|
| committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 1999-07-22 16:29:42 -0300 |
| commit | e9a670695a764408aae2bd970ded7a58d98921c4 (patch) | |
| tree | 4e6b456f909090fced8aad436b6491601a85bfca /lparser.c | |
| parent | 16024861bd23ac9f837f956fbeec739878e5d895 (diff) | |
| download | lua-e9a670695a764408aae2bd970ded7a58d98921c4.tar.gz lua-e9a670695a764408aae2bd970ded7a58d98921c4.tar.bz2 lua-e9a670695a764408aae2bd970ded7a58d98921c4.zip | |
details
Diffstat (limited to '')
| -rw-r--r-- | lparser.c | 8 |
1 files changed, 4 insertions, 4 deletions
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | ** $Id: lparser.c,v 1.36 1999/06/16 13:35:01 roberto Exp roberto $ | 2 | ** $Id: lparser.c,v 1.37 1999/06/17 17:04:03 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 | */ |
| @@ -145,7 +145,7 @@ static void var_or_func_tail (LexState *ls, vardesc *v); | |||
| 145 | static void checklimit (LexState *ls, int val, int limit, char *msg) { | 145 | static void checklimit (LexState *ls, int val, int limit, char *msg) { |
| 146 | if (val > limit) { | 146 | if (val > limit) { |
| 147 | char buff[100]; | 147 | char buff[100]; |
| 148 | sprintf(buff, "too many %s (limit=%d)", msg, limit); | 148 | sprintf(buff, "too many %.50s (limit=%d)", msg, limit); |
| 149 | luaX_error(ls, buff); | 149 | luaX_error(ls, buff); |
| 150 | } | 150 | } |
| 151 | } | 151 | } |
| @@ -617,7 +617,7 @@ static void next (LexState *ls) { | |||
| 617 | static void error_expected (LexState *ls, int token) { | 617 | static void error_expected (LexState *ls, int token) { |
| 618 | char buff[100], t[TOKEN_LEN]; | 618 | char buff[100], t[TOKEN_LEN]; |
| 619 | luaX_token2str(token, t); | 619 | luaX_token2str(token, t); |
| 620 | sprintf(buff, "`%s' expected", t); | 620 | sprintf(buff, "`%.20s' expected", t); |
| 621 | luaX_error(ls, buff); | 621 | luaX_error(ls, buff); |
| 622 | } | 622 | } |
| 623 | 623 | ||
| @@ -635,7 +635,7 @@ static void error_unmatched (LexState *ls, int what, int who, int where) { | |||
| 635 | char t_what[TOKEN_LEN], t_who[TOKEN_LEN]; | 635 | char t_what[TOKEN_LEN], t_who[TOKEN_LEN]; |
| 636 | luaX_token2str(what, t_what); | 636 | luaX_token2str(what, t_what); |
| 637 | luaX_token2str(who, t_who); | 637 | luaX_token2str(who, t_who); |
| 638 | sprintf(buff, "`%s' expected (to close `%s' at line %d)", | 638 | sprintf(buff, "`%.20s' expected (to close `%.20s' at line %d)", |
| 639 | t_what, t_who, where); | 639 | t_what, t_who, where); |
| 640 | luaX_error(ls, buff); | 640 | luaX_error(ls, buff); |
| 641 | } | 641 | } |
