aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Removed unused function 'luaD_inctop'HEADmasterRoberto I2026-06-032-7/+0
| | | | Commit 3228a97 removed all its uses.
* Cleaning 'luaP_isIT' and 'luaP_isOT'Roberto I2026-05-283-23/+17
| | | | | | - 'luaP_isOT' is only used for tests, so it is defined as a macro to avoid wasting space with an unused function. - 'luaP_isIT' must include OP_VARARGPREP.
* Avoid warning in some compilersRoberto I2026-05-081-0/+1
| | | | | In function 'funcargs', some compilers can complain that 'args' can be used unitialized, due to the default case (syntax error).
* Small correction in luaP_opmodesRoberto I2026-04-291-1/+1
| | | | OP_VARARGPREP neither sets nor uses L->top.
* DetailsRoberto Ierusalimschy2026-04-283-7/+12
|
* new macro 'setnilvalue2s'Roberto I2026-04-239-23/+24
|
* 'load' reader function doesn't need to preserve stackRoberto I2026-04-231-18/+9
|
* Bug: 'lua_load' does not preserve the stackRoberto I2026-04-237-27/+77
| | | | | | | 'lua_load' does not preserve the stack through the calls to the reader function, as it should. Immediately after the first call (to detect whether chunk is binary) it adds stuff, and it also adds a new table when starting the compilation of each new function.
* DetailsRoberto I2026-04-212-11/+21
| | | | | Added compiler option LUA_NODEBUGLIB to make Lua with no open debug library + small improvements in the manual.
* Better error messages for vararg-table fieldsRoberto I2026-04-132-1/+4
|
* Avoid macros luaL_loadbuffer and luaL_loadfileRoberto I2026-04-076-15/+17
| | | | | Use luaL_loadbufferx and luaL_loadfilex instead, being explicit about whether to accept binary chunks.
* Stricter test for use of '__builtin_expect'Roberto I2026-04-011-1/+1
| | | | GCC introduced this macro in version 3.
* Bug: wrong initialization in result from 'gmatch'Roberto Ierusalimschy2026-04-012-2/+18
| | | | | Function returned by 'string.gmatch' can be left in an inconsistent state after an error.
* Bug: Loading a binary chunk does not run the GCRoberto I2026-04-011-0/+1
|
* Adjustment in useless parameter L in macros luai_num*Roberto I2026-03-152-9/+9
|
* 'table.tunpack' using 'aux_getn' like the othersRoberto I2026-03-092-4/+20
| | | | | | 'table.tunpack' was not checking its first argument, which could result in error messages generated inside the API, without location information.
* DetailsRoberto I2026-03-092-2/+2
|
* Slightly better documentation for LUAI_MAXALIGNRoberto I2026-03-092-4/+15
|
* BUG: shift overflow in utf-8 decodeRoberto I2026-02-183-3/+18
| | | | | An initial byte \xFF will ask for 7 continuation bytes, and then the shift by (count * 5) will try to shift 35 bits.
* DetailsRoberto Ierusalimschy2026-02-102-10/+10
| | | | | Spaces + added initialization to the documentation of global declarations.
* Avoid an assignment of values that overlapRoberto Ierusalimschy2026-02-091-4/+5
| | | | | | The original code was like this, where t->u.ind.t and t->u.info overlap: t->u.ind.t = cast_byte((t->k == VLOCAL) ? t->u.var.ridx: t->u.info);
* Environment variable for readline library nameRoberto I2026-01-302-7/+40
| | | | | The name of the readline library can be changed from its default value through environment variable LUA_READLINELIB.
* New year and (eventual) new releaseRoberto I2026-01-292-4/+4
|
* Explanation about char* parameters in the C APIRoberto I2026-01-231-1/+13
|
* Another way to handle option -ERoberto I2026-01-221-6/+16
| | | | | | A pointer to function 'l_getenv' can point to the regular 'getenv' or to a dumb function (that always returns NULL) to ignore environment variables.
* Some compilation options configurable from makefileRoberto Ierusalimschy2026-01-205-5/+20
| | | | | | Compilation options LUA_COMPAT_GLOBAL, LUA_COMPAT_LOOPVAR, and LUA_READLINELIB do not affect the API, so they can be changed through the make file.
* New compile option LUA_COMPAT_LOOPVARRoberto I2026-01-162-2/+18
| | | | When on, this option makes for-loop control variables not read only.
* More effort in avoiding errors in finalizersRoberto I2026-01-118-16/+118
| | | | | | | | Before calling a finalizer, Lua not only checks stack limits, but actually ensures that a minimum number of slots are already allocated for the call. (If it cannot ensure that, it postpones the finalizer.) That avoids finalizers not running due to memory errors that the programmer cannot control.
* Special case for 'string.rep' over an empty stringRoberto I2026-01-042-5/+5
|
* BUG: Possible overflow in 'string.packsize'Roberto I2026-01-041-1/+1
| | | | | 'string.packsize' can overflow result in 32-bit machines using 64-bit integers, as LUA_MAXINTEGER may not fit into size_t.
* DetailsRoberto I2026-01-041-4/+5
| | | | | In an assignment like 'a = &b', is looks suspicious if 'a' has a scope larger than 'b'.
* DetailsRoberto I2025-12-302-5/+4
| | | | | Some comments still talked about bit 'isrealasize', which has been removed.
* BUG: Arithmetic overflow in 'collectgarbage"step"'Roberto I2025-12-271-2/+7
| | | | | | | The computation of a new debt could overflow when we give a too large step to 'collectgarbage"step"' and the current debt was already negative. This is only an issue if your platform cares for it or if you compile Lua with an option like '-fsanitize=undefined'.
* DetailsRoberto I2025-12-233-3/+3
| | | | | typo in comment + formatting + logical 'and' was written as a bitwise operation (makes code more fragile)
* GC checks stack space before running finalizerv5.5.0Roberto I2025-12-133-3/+16
| | | | | | If the stack does not have some minimum available space, the GC defers calling a finalizer until the next cycle. That avoids errors while running a finalizer that the programmer cannot control.
* 'luaL_newstate' starts state with warnings onRoberto I2025-12-132-2/+3
| | | | It is easier to forget to turn them on then to turn them off.
* Format adjust in the manualRoberto I2025-12-101-19/+19
| | | | | Lists in inline code don't get a space after commas. (That keeps the code more compact and avoids line breaks in the middle of the code.)
* DetailsRoberto I2025-12-082-8/+8
| | | | | - Avoid fixing name "_ENV" in the code - Small improvements in the manual
* Wrong assert in 'luaK_indexed'Roberto I2025-12-081-3/+5
|
* In luaB_close, running coroutines do not go to defaultrcRoberto I2025-12-011-4/+6
| | | | This should had been corrected in commit fd897027f1.
* Functions with vararg tables don't need hidden args.Roberto I2025-11-289-43/+70
| | | | | Vararg functions with vararg tables don't use the arguments hidden in the stack; therfore, it doesn't need to build/keep them.
* New conceptual model for varargRoberto I2025-11-2611-69/+154
| | | | | | Conceptually, all functions get their vararg arguments in a vararg table. The storing of vararg arguments in the stack is always treated as an optimization.
* DetailsRoberto I2025-11-243-16/+23
| | | | Comments, capitalization in the manual, globals in test 'heady.lua'
* '__pairs' can also return a to-be-closed objectRoberto I2025-11-113-9/+15
|
* External strings are as good as internal onesRoberto I2025-11-114-6/+28
| | | | A '__mode' metafield and an "n" key both can be external strings.
* Correction in line info for semantic errorsRoberto I2025-11-112-22/+43
| | | | Semantic errors should refer the last used token, not the next one.
* Global initialization checks name conflictRoberto I2025-11-0813-9/+87
| | | | | Initialization "global a = 10" raises an error if global 'a' is already defined, that is, it has a non-nil value.
* DetailsRoberto I2025-10-313-8/+10
| | | | | | - New macro l_strcoll to ease changing 'strcoll' to something else. - MAXINDEXRK==1 in 'ltests.h' is enough to run test 'code.lua'. - Removed unused '#include' in 'lutf8lib.c'.
* Vertical bar removed from syntax of vararg tableRoberto I2025-10-305-22/+20
| | | | | | The syntax 'function foo (a, b, ...arg)' is already used by JavaScript for this same semantics, so it seems natural to use the same notation in Lua.
* Case VVARGIND added to luaK_storevarRoberto Ierusalimschy2025-10-302-0/+16
| | | | | | In a global initialization, the variable does not pass through 'check_readonly', and therefore a VVARGIND is not normalized to a VINDEXED.