Roberto Ierusalimschy
65434b4d1b
Option '-l' can give a name for the global variable.
Sintax for this option now is '-l [globname=]modname'.
3 years ago
Roberto Ierusalimschy
131e3fd814
Avoid using 'signal' when 'sigaction' is available
The semantics of 'signal' varies a lot among different implementations;
'sigaction' ensures a more consistent behavior.
4 years ago
Roberto Ierusalimschy
69b71a6919
_PROMPT can have non-string values
'get_prompt' uses 'luaL_tolstring' to convert _PROMPT or _PROMPT2
value to a string. That conversion may invoke a '__tostring'
metamethod.
4 years ago
Roberto Ierusalimschy
17dbaa8639
Improvements in the handling of signals
Added 'volatile' to 'l_signalT' variables plus some minor changes.
5 years ago
Roberto Ierusalimschy
be78aeae4c
Default for warnings changed to "off"
Warnings are mostly a tool to help developers (e.g., by showing hidden
error messages); regular users usually don't need to see them.
5 years ago
Roberto Ierusalimschy
a1d8eb2743
Added control messages to warnings
Added the concept of control messages to the warning system, plus the
implementation of the controls "@on"/"@off" to turn warnings on/off.
Moreover, the warning system in the test library adds some other
controls to ease the test of warnings.
5 years ago
Roberto Ierusalimschy
faaf7e481f
Removed use of 'rl_inhibit_completion' in 'lua.c'
Some old systems (e.g., Mac OS X 10.4) do not define
'rl_inhibit_completion', even when line history is available.
Anyway, the user can configure this option externally, using '~/.inputrc'.
6 years ago
Roberto Ierusalimschy
c3cb31fa9a
some extra goodies for 'readline'
('rl_readline_name' and 'rl_inhibit_completion')
7 years ago
Roberto Ierusalimschy
464658b16a
better modularization of the code for the REPL
7 years ago
Roberto Ierusalimschy
fc3eaa2559
GC default mode for the stand-alone interpreter is generational mode
7 years ago
Roberto Ierusalimschy
4804bbd9bb
include first standard header files
(Some broken compiler has problems with 'signal.h' being included
without a definition for 'size_t'.)
8 years ago
Roberto Ierusalimschy
9e1f1b1f62
detail in usage message for '-l' option
8 years ago
Roberto Ierusalimschy
94c1b3a8ee
Handling of LUA_PATH/LUA_CPATH moved back to 'package' library
to avoid incompatibilites with previous releases
8 years ago
Roberto Ierusalimschy
2a235312f0
detail (removing spaces at end of lines)
8 years ago
Roberto Ierusalimschy
9f594ca6f5
LUA_PATHSUFFIX -> LUA_VERSUFFIX + LUA_VERSUFFIX used in the
definition of LUA_INITVARVERSION, too.
8 years ago
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)
8 years ago
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)
9 years ago
Roberto Ierusalimschy
3a91274547
details (avoid 'lint' warnings)
10 years ago
Roberto Ierusalimschy
fd6e680e21
detail
10 years ago
Roberto Ierusalimschy
57c0db219b
line history keep lines without added 'return'
10 years ago
Roberto Ierusalimschy
87b179e71d
detail (use new returned value from 'lua_getglobal' )
10 years ago
Roberto Ierusalimschy
e75c0148c3
comments (references to "ANSI C" changed to "ISO C", which is the
international name
10 years ago
Roberto Ierusalimschy
28fdbcf393
added include for 'lprefix.h', for stuff that must be added before
any other header file
10 years ago
Roberto Ierusalimschy
1a69a3ecea
LUA_WIN -> LUA_USE_WINDOWS
10 years ago
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)
10 years ago
Roberto Ierusalimschy
6d613817d4
comments
10 years ago
Roberto Ierusalimschy
961760c9b6
message handler always adds a traceback to messages (even if they
are not strings), unless they have a __tostring method.
10 years ago
Roberto Ierusalimschy
f97c64d7bf
macros 'LUA_QL'/'LUA_QL' deprecated
10 years ago
Roberto Ierusalimschy
8ede2c353c
detail in 'report' + message handler always is called with an
argument + 'report' already handles non-string error messages
10 years ago
Roberto Ierusalimschy
b9dcf9974d
detail (typos in comments)
11 years ago
Roberto Ierusalimschy
10200585a7
var-arguments to the script come from 'arg' table (not from original
'argv' array)
11 years ago
Roberto Ierusalimschy
23f0ff9517
lots of janitor work (including comments) + 'arg' table created
before running any script + changes in the parameters and return
of 'collectargs'
11 years ago
Roberto Ierusalimschy
c6c41e85b2
more uniformity for defining system-dependent features
11 years ago
Roberto Ierusalimschy
1721d09ac8
still accepts initial '=' for expressions, for compatibility with old
versions (and old habits...)
11 years ago
Roberto Ierusalimschy
1a19893d6f
new "calculator mode"; no need to add '=' to print expressions
11 years ago
Roberto Ierusalimschy
c5fcba1a17
detail (changing some names of macros)
11 years ago
Roberto Ierusalimschy
ab7086e209
pops the string from 'get_prompt' only after using it
12 years ago
Roberto Ierusalimschy
054c20cd5b
spaces -> tabs in #defines
13 years ago
Roberto Ierusalimschy
4cca1a436d
details (using lua_setglobal/lua_getglobal instead of explicit
use of the global table)
13 years ago
Roberto Ierusalimschy
e2fc2ce8df
new way to handle -E option (write a mark in the registry to avoid
reading environment variables)
13 years ago
Roberto Ierusalimschy
166dd0261a
new option '-E' to avoid environment variables
13 years ago
Roberto Ierusalimschy
6a5d89b39f
detail (using array instead of several variables to keep track of
enabled command-line options)
13 years ago
Roberto Ierusalimschy
beab626061
correct length for LUA_COPYRIGHT (without trailing '\0')
14 years ago
Roberto Ierusalimschy
ee7d0c2649
new macro 'luai_writeline' to print newlines (and flush 'stdout')
14 years ago
Roberto Ierusalimschy
ad2531a0ee
more complete (and hopefuly more correct) handling of 'sizeof(char)'
14 years ago
Roberto Ierusalimschy
682cce3813
macro 'mark' renamed 'EOFMARK' ('mark' is too easy to confict, e.g.
in alllua.c)
14 years ago
Roberto Ierusalimschy
094a7d0290
detail in 'print_usage'
14 years ago
Roberto Ierusalimschy
ac3afc7cd4
'printf' replaced by 'luai_writestring'
14 years ago
Roberto Ierusalimschy
4590a89b32
corrected warnings from different compilers (mostly casts and small
details)
14 years ago
Roberto Ierusalimschy
a122688091
better error message for 'lua -e -i'
14 years ago