Commit Graph

251 Commits

Author SHA1 Message Date
Roberto Ierusalimschy
063d4e4543 Lua 5.3.5 ported to git
This is the first commit for the branch Lua 5.3. All source files
were copied from the official distribution of 5.3.5 in the Lua site.
The test files are the same of 5.3.4. The manual came from the
previous RCS repository, revision 1.167.1.2.
2018-12-17 14:46:37 -02:00
Roberto Ierusalimschy
94c1b3a8ee Handling of LUA_PATH/LUA_CPATH moved back to 'package' library
to avoid incompatibilites with previous releases
2017-01-12 15:14:26 -02:00
Roberto Ierusalimschy
2a235312f0 detail (removing spaces at end of lines) 2016-12-22 11:08:50 -02:00
Roberto Ierusalimschy
9f594ca6f5 LUA_PATHSUFFIX -> LUA_VERSUFFIX + LUA_VERSUFFIX used in the
definition of LUA_INITVARVERSION, too.
2016-12-13 13:50:58 -02:00
Roberto Ierusalimschy
de3fd8ab83 Handling of LUA_PATH/LUA_CPATH moved from package library to stand
alone interpreter (so that 'lua.c' concentrates all handling of
environment variables)
2016-07-18 14:55:59 -03:00
Roberto Ierusalimschy
ed19fe766c added ';' at the end of "expression lines" ("return exp;") so that
an extra ";" at the end is enough to stop Lua printing the result
("return exp;;" is not valid)
2015-08-14 16:11:20 -03:00
Roberto Ierusalimschy
3a91274547 details (avoid 'lint' warnings) 2015-03-30 12:42:59 -03:00
Roberto Ierusalimschy
fd6e680e21 detail 2015-03-10 11:15:06 -03:00
Roberto Ierusalimschy
57c0db219b line history keep lines without added 'return' 2015-03-09 18:57:05 -03:00
Roberto Ierusalimschy
87b179e71d detail (use new returned value from 'lua_getglobal' ) 2014-11-11 17:41:27 -02:00
Roberto Ierusalimschy
e75c0148c3 comments (references to "ANSI C" changed to "ISO C", which is the
international name
2014-11-02 17:33:33 -02:00
Roberto Ierusalimschy
28fdbcf393 added include for 'lprefix.h', for stuff that must be added before
any other header file
2014-11-02 17:19:04 -02:00
Roberto Ierusalimschy
1a69a3ecea LUA_WIN -> LUA_USE_WINDOWS 2014-10-31 13:54:06 -02:00
Roberto Ierusalimschy
05afee0f50 definitions for 'luai_writestring'/'luai_writeline'/'luai_writestringerror'
moved to 'lauxlib.h' (they do not need to be stable or configurable) +
prefixes changed from 'luai_' to 'lua_' (they are not part of the core)
2014-10-29 14:12:30 -02:00
Roberto Ierusalimschy
6d613817d4 comments 2014-10-20 20:21:05 -02:00
Roberto Ierusalimschy
961760c9b6 message handler always adds a traceback to messages (even if they
are not strings), unless they have a __tostring method.
2014-10-20 16:19:26 -02:00
Roberto Ierusalimschy
f97c64d7bf macros 'LUA_QL'/'LUA_QL' deprecated 2014-10-17 13:28:21 -03:00
Roberto Ierusalimschy
8ede2c353c detail in 'report' + message handler always is called with an
argument + 'report' already handles non-string error messages
2014-09-25 11:20:37 -03:00
Roberto Ierusalimschy
b9dcf9974d detail (typos in comments) 2014-06-30 16:48:08 -03:00
Roberto Ierusalimschy
10200585a7 var-arguments to the script come from 'arg' table (not from original
'argv' array)
2014-06-26 14:08:52 -03:00
Roberto Ierusalimschy
23f0ff9517 lots of janitor work (including comments) + 'arg' table created
before running any script + changes in the parameters and return
of 'collectargs'
2014-06-05 17:42:06 -03:00
Roberto Ierusalimschy
c6c41e85b2 more uniformity for defining system-dependent features 2014-02-26 12:27:56 -03:00
Roberto Ierusalimschy
1721d09ac8 still accepts initial '=' for expressions, for compatibility with old
versions (and old habits...)
2014-02-05 12:22:55 -02:00
Roberto Ierusalimschy
1a19893d6f new "calculator mode"; no need to add '=' to print expressions 2013-12-16 12:27:17 -02:00
Roberto Ierusalimschy
c5fcba1a17 detail (changing some names of macros) 2013-10-07 11:20:31 -03:00
Roberto Ierusalimschy
ab7086e209 pops the string from 'get_prompt' only after using it 2012-09-29 17:07:06 -03:00
Roberto Ierusalimschy
054c20cd5b spaces -> tabs in #defines 2012-05-23 12:37:09 -03:00
Roberto Ierusalimschy
4cca1a436d details (using lua_setglobal/lua_getglobal instead of explicit
use of the global table)
2012-04-20 14:05:17 -03:00
Roberto Ierusalimschy
e2fc2ce8df new way to handle -E option (write a mark in the registry to avoid
reading environment variables)
2011-12-12 14:34:03 -02:00
Roberto Ierusalimschy
166dd0261a new option '-E' to avoid environment variables 2011-08-17 17:19:52 -03:00
Roberto Ierusalimschy
6a5d89b39f detail (using array instead of several variables to keep track of
enabled command-line options)
2011-08-04 15:16:16 -03:00
Roberto Ierusalimschy
beab626061 correct length for LUA_COPYRIGHT (without trailing '\0') 2011-06-16 11:30:58 -03:00
Roberto Ierusalimschy
ee7d0c2649 new macro 'luai_writeline' to print newlines (and flush 'stdout') 2011-05-26 13:09:40 -03:00
Roberto Ierusalimschy
ad2531a0ee more complete (and hopefuly more correct) handling of 'sizeof(char)' 2011-05-03 13:01:57 -03:00
Roberto Ierusalimschy
682cce3813 macro 'mark' renamed 'EOFMARK' ('mark' is too easy to confict, e.g.
in alllua.c)
2011-03-14 12:39:42 -03:00
Roberto Ierusalimschy
094a7d0290 detail in 'print_usage' 2011-02-07 10:27:13 -02:00
Roberto Ierusalimschy
ac3afc7cd4 'printf' replaced by 'luai_writestring' 2010-12-03 15:20:50 -02:00
Roberto Ierusalimschy
4590a89b32 corrected warnings from different compilers (mostly casts and small
details)
2010-10-25 17:01:37 -02:00
Roberto Ierusalimschy
a122688091 better error message for 'lua -e -i' 2010-10-18 14:06:33 -02:00
Roberto Ierusalimschy
73b0a3451d environment variables consulted by Lua may be version-specific 2010-07-25 12:03:37 -03:00
Roberto Ierusalimschy
7631c29b2f comand-line option '-l' creates global with given name after
requiring module
2010-07-02 14:36:32 -03:00
Roberto Ierusalimschy
afdb19ac82 no more 'ccall' nor 'cpcall' functions. (With light C functions they
are obsolete.)
2010-04-14 12:14:21 -03:00
Roberto Ierusalimschy
489253d753 better definitions for lua_[gs]etglobal + less uses of ENVIRONINDEX 2010-03-13 00:57:46 -03:00
Roberto Ierusalimschy
622e448710 removed useless test (argv[i] cannot be NULL when i<argc) 2010-02-27 18:15:36 -03:00
Roberto Ierusalimschy
4274738e81 new macro 'luai_writestringerror' 2010-02-18 17:18:41 -02:00
Roberto Ierusalimschy
0d7d559dcc no need to flush either stderr or \n-terminated outputs 2010-02-11 15:12:27 -02:00
Roberto Ierusalimschy
a838b3b496 better usage messages, showing entire offending argument 2010-02-09 09:58:57 -02:00
Roberto Ierusalimschy
4f5f2fe367 new function 'luaL_cpcall' 2010-01-21 14:49:21 -02:00
Roberto Ierusalimschy
c8ab34ab7a better messages for invalid options 2010-01-21 14:31:06 -02:00
Roberto Ierusalimschy
cc1cbd19a0 'lua_cpcall' is deprecated + other small changes in 'pmain' (comments
and reordering to check arguments before running any Lua code)
2009-12-22 14:47:12 -02:00