diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2002-07-08 15:14:36 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2002-07-08 15:14:36 -0300 |
commit | d2d24f09713cfecf59a7688c45a3863a35f09254 (patch) | |
tree | 7ee3aaf0b2989bf257cabe010f8f558db0f503fa | |
parent | 0436c96866851f4081286f86500cb36c47fb27a5 (diff) | |
download | lua-d2d24f09713cfecf59a7688c45a3863a35f09254.tar.gz lua-d2d24f09713cfecf59a7688c45a3863a35f09254.tar.bz2 lua-d2d24f09713cfecf59a7688c45a3863a35f09254.zip |
details to allow compilation of Lua as a single file
-rw-r--r-- | llex.c | 9 |
1 files changed, 5 insertions, 4 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: llex.c,v 1.105 2002/06/18 15:19:27 roberto Exp roberto $ | 2 | ** $Id: llex.c,v 1.106 2002/06/25 19:18:20 roberto Exp roberto $ |
3 | ** Lexical Analyzer | 3 | ** Lexical Analyzer |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -160,7 +160,7 @@ static size_t readname (LexState *LS) { | |||
160 | 160 | ||
161 | 161 | ||
162 | /* LUA_NUMBER */ | 162 | /* LUA_NUMBER */ |
163 | static void read_number (LexState *LS, int comma, SemInfo *seminfo) { | 163 | static void read_numeral (LexState *LS, int comma, SemInfo *seminfo) { |
164 | lua_State *L = LS->L; | 164 | lua_State *L = LS->L; |
165 | size_t l = 0; | 165 | size_t l = 0; |
166 | checkbuffer(L, l); | 166 | checkbuffer(L, l); |
@@ -367,7 +367,7 @@ int luaX_lex (LexState *LS, SemInfo *seminfo) { | |||
367 | } | 367 | } |
368 | else if (!isdigit(LS->current)) return '.'; | 368 | else if (!isdigit(LS->current)) return '.'; |
369 | else { | 369 | else { |
370 | read_number(LS, 1, seminfo); | 370 | read_numeral(LS, 1, seminfo); |
371 | return TK_NUMBER; | 371 | return TK_NUMBER; |
372 | } | 372 | } |
373 | } | 373 | } |
@@ -380,7 +380,7 @@ int luaX_lex (LexState *LS, SemInfo *seminfo) { | |||
380 | continue; | 380 | continue; |
381 | } | 381 | } |
382 | else if (isdigit(LS->current)) { | 382 | else if (isdigit(LS->current)) { |
383 | read_number(LS, 0, seminfo); | 383 | read_numeral(LS, 0, seminfo); |
384 | return TK_NUMBER; | 384 | return TK_NUMBER; |
385 | } | 385 | } |
386 | else if (isalpha(LS->current) || LS->current == '_') { | 386 | else if (isalpha(LS->current) || LS->current == '_') { |
@@ -405,3 +405,4 @@ int luaX_lex (LexState *LS, SemInfo *seminfo) { | |||
405 | } | 405 | } |
406 | } | 406 | } |
407 | 407 | ||
408 | #undef next | ||