Commit Graph

  • 513c639bf9 patch for last bug corrected to be against last released version (and not against last version in RCS...) Roberto Ierusalimschy 2015-04-13 13:13:25 -03:00
  • 69b5f7a410 some details in 'luaO_int2fb' + more consistent use of the locale decimal point Roberto Ierusalimschy 2015-04-11 15:30:08 -03:00
  • ae76c39712 Bug: suspended '__le' metamethod can give wrong result Roberto Ierusalimschy 2015-04-10 14:56:25 -03:00
  • 0d4a1f71db re-organization of initial configuration options Roberto Ierusalimschy 2015-04-10 14:41:04 -03:00
  • 67bf789462 avoid using API functions inside the core Roberto Ierusalimschy 2015-04-06 09:23:48 -03:00
  • 48d0674c2e more consistent use of locale radix character across Lua Roberto Ierusalimschy 2015-04-03 15:41:57 -03:00
  • 6ffe006f5c detail (removed unused macro VARBITS) Roberto Ierusalimschy 2015-04-02 18:10:53 -03:00
  • 4998e852ec new function 'log2' to test 'luaO_ceillog2' (if needed) Roberto Ierusalimschy 2015-04-02 18:10:21 -03:00
  • 65ac789565 detail (comment) Roberto Ierusalimschy 2015-04-02 18:09:51 -03:00
  • cfc84c856d 'LUA_REAL_*' -> 'LUA_FLOAT_*' (everywhere else we are using 'float') Roberto Ierusalimschy 2015-03-31 09:00:07 -03:00
  • 63720a4290 janitor work (comments, variable names, some other details) Roberto Ierusalimschy 2015-03-30 16:51:00 -03:00
  • 484bf14a6b calls to 'luaC_checkGC' in luaD_precall moved near to 'luaD_checkstack' (which is what can need memory) Roberto Ierusalimschy 2015-03-30 13:05:23 -03:00
  • abb2f5511d detail ('b + base' -> 'base + b' to follow all other similar uses) Roberto Ierusalimschy 2015-03-30 12:45:01 -03:00
  • fcc6e1220e avoid expression with side effect (in debug mode) inside 'sizeof' Roberto Ierusalimschy 2015-03-30 12:43:51 -03:00
  • 3a91274547 details (avoid 'lint' warnings) Roberto Ierusalimschy 2015-03-30 12:42:59 -03:00
  • f2a813ae10 details (avoid some 'lint' warnings) Roberto Ierusalimschy 2015-03-28 16:16:55 -03:00
  • e723c75c02 details (avoid 'lint' warnings) Roberto Ierusalimschy 2015-03-28 16:14:47 -03:00
  • b436ed58a3 'clearapihash' -> 'luaS_clearcache' and moved to 'lstring.c' (which keeps all code related to this cache) Roberto Ierusalimschy 2015-03-25 10:42:19 -03:00
  • 2b37f2150e comments Roberto Ierusalimschy 2015-03-14 14:58:57 -03:00
  • 331632e8d8 code detail ('if' -> '?:') Roberto Ierusalimschy 2015-03-13 13:24:50 -03:00
  • 7d930ec694 use 'log2' when available Roberto Ierusalimschy 2015-03-12 11:04:04 -03:00
  • 0cf3b6495a 'ci_func' don't need to be exported Roberto Ierusalimschy 2015-03-11 13:10:41 -03:00
  • b66fedadae 'lua_pushliteral' implemented with 'lua_pushstring' (to take advantage of the cache) Roberto Ierusalimschy 2015-03-10 11:17:51 -03:00
  • fd6e680e21 detail Roberto Ierusalimschy 2015-03-10 11:15:06 -03:00
  • 57c0db219b line history keep lines without added 'return' Roberto Ierusalimschy 2015-03-09 18:57:05 -03:00
  • 4ba0cb4580 always use macros to operate on lua_Numbers Roberto Ierusalimschy 2015-03-07 16:30:16 -03:00
  • a30c66f0fc macro 'luai_apicheck'/'api_check' back with a 'lua_State' parameter (some people use it) Roberto Ierusalimschy 2015-03-06 16:49:50 -03:00
  • bb4baa73ea allocation function is not exactly API (and cannot raise errors like other API functions); better not use 'api_check' for cheking it. Roberto Ierusalimschy 2015-03-06 16:45:54 -03:00
  • d7d44b038d detail (use 'lua_pushliteral' to push an empty string) Roberto Ierusalimschy 2015-03-06 16:09:08 -03:00
  • 297512b34c avoid using 'lua_pushliteral' in a non-zero-terminated string Roberto Ierusalimschy 2015-03-05 13:07:46 -03:00
  • 2ae2e6408e avoid testing for NULL when marking objects that cannot be NULL Roberto Ierusalimschy 2015-03-04 10:51:55 -03:00
  • a80cada914 new cache for interning strings Roberto Ierusalimschy 2015-03-04 10:31:21 -03:00
  • a00013c8d0 'point2int' -> 'point2uint' (to reflect its actual result type) Roberto Ierusalimschy 2015-03-03 16:53:13 -03:00
  • b9a1f27250 do not attempt emergency collection while building state (it is useless, and state can be inconsistent) Roberto Ierusalimschy 2015-03-03 15:18:29 -03:00
  • 29aed28802 detail (use 'luaS_newliteral' when possible) Roberto Ierusalimschy 2015-03-03 15:17:04 -03:00
  • 951b562cf8 configuration for numerical types through only one #define for each type Roberto Ierusalimschy 2015-03-02 13:59:01 -03:00
  • 6408bc0b7f new macros 'chgfltvalue'/'chgivalue' (numerical for loop does not need to set the type of its internal variable at each iteration) Roberto Ierusalimschy 2015-03-02 13:04:52 -03:00
  • 91efb4b895 LUA_COMPAT_5_1 needs some options deprecated from 5.2 to 5.3 Roberto Ierusalimschy 2015-02-28 16:22:31 -03:00
  • 27c5b1b237 added patches to two bugs Roberto Ierusalimschy 2015-02-23 16:20:43 -03:00
  • d51bdc166d bug: 'string.format("%f")' can cause a buffer overflow (with long doubles) bug: 'debug.getlocal' on a coroutine suspended in a hook can crash the interpreter Roberto Ierusalimschy 2015-02-20 16:21:29 -02:00
  • 81245b1ad5 'numisinteger' (for table keys) replaced by 'luaV_tointeger' (old 'tointeger_aux'), which can do the same job. Roberto Ierusalimschy 2015-02-20 12:27:53 -02:00
  • 397ce11996 make 'hashfloat' configurable Roberto Ierusalimschy 2015-02-20 12:05:01 -02:00
  • 97f2aa5a44 bug: when manipulating other threads, there is no garanties about their stack space Roberto Ierusalimschy 2015-02-19 15:06:21 -02:00
  • 419e2cb01d detail (file does not need 'string.h') Roberto Ierusalimschy 2015-02-16 11:15:00 -02:00
  • 374f6c4612 detail ('fopen' needs 'stdio.h') Roberto Ierusalimschy 2015-02-16 11:14:33 -02:00
  • 4bdf9962bf bug: suspended function can have its 'func' field not pointing to its function, crashing debug functions Roberto Ierusalimschy 2015-02-13 14:01:17 -02:00
  • e0306e386f some changes in 'hashfloat' to avoid undefined (in ISO C) numerical conversions Roberto Ierusalimschy 2015-02-13 11:05:34 -02:00
  • 2e6e53c7cc added API checks to some unprotected 'top' increments Roberto Ierusalimschy 2015-02-11 16:47:22 -02:00
  • 2a57d2346e detail Roberto Ierusalimschy 2015-02-09 16:05:46 -02:00
  • 7e425be975 bug (in 5.2): Chunk with too many lines can seg. fault Roberto Ierusalimschy 2015-02-09 15:57:45 -02:00
  • 0705e7b39f detail (no need to write 'double' in source) Roberto Ierusalimschy 2015-02-09 15:41:54 -02:00
  • 4ccc4578b3 detail (use 'l_floor' instead of 'l_mathop(floor)') Roberto Ierusalimschy 2015-02-09 13:41:56 -02:00
  • 5e8c162b6c detail Roberto Ierusalimschy 2015-02-05 15:50:24 -02:00
  • c8d6cb0136 macros 'luai_num*' (for float arithmetic operations) moved to llimits.h. Roberto Ierusalimschy 2015-02-05 15:15:33 -02:00
  • 0edcdf49c0 added comments documenting LUA_NOCVTN2S/LUA_NOCVTS2N Roberto Ierusalimschy 2015-02-05 14:53:34 -02:00
  • b7dfd18612 make buffer for format specification a little larger (length modifier can be larger than 2, e.g. "I64") Roberto Ierusalimschy 2015-02-04 10:54:31 -02:00
  • 8efcd411fe own implementation for 'string.format("%a")' for C89 platforms Roberto Ierusalimschy 2015-02-04 10:52:57 -02:00
  • 90d016980f detail ('luaL_getmetatable' does not return a boolean, but a tag) Roberto Ierusalimschy 2015-02-03 15:38:24 -02:00
  • b3996c55f6 LUAL_BUFFERSIZE affects the API, so it is better not to change it between releases of the same version. (The long double case seems to be too rare, so that should not be a problem; moreover, that case is related to a bug) Roberto Ierusalimschy 2015-01-16 15:26:56 -02:00
  • 438a9fcc78 LUAI_MAXSHORTLEN moved from 'luaconf.h' to 'llimits.h' (does not affect the API and is seldom modified) Roberto Ierusalimschy 2015-01-16 15:15:52 -02:00
  • 7e2015a46d size of short strings stored in a single byte, to reduce the size of struct 'TString' Roberto Ierusalimschy 2015-01-16 14:54:37 -02:00
  • 5b01cb39b5 larger MINSTRTABSIZE (standard Lua starts with ~230 strings, after oppening the standard libraries) Roberto Ierusalimschy 2015-01-16 13:41:03 -02:00
  • a0503305bd comments Roberto Ierusalimschy 2015-01-16 11:26:55 -02:00
  • 965f74525b removed macro LUAI_FIRSTPSEUDOIDX (that stuff does not need to be configurable) Roberto Ierusalimschy 2015-01-13 17:50:30 -02:00
  • 3f2e21f0ea Long double needs a larger LUAL_BUFFERSIZE (because 'string.format("%.99f", 1e4900)' can generate quite long strings), but otherwise buffer can be 1~2K Roberto Ierusalimschy 2015-01-13 15:24:22 -02:00
  • 3509914916 BUG (when compiled with long double): buffer overflow when formatting string.format("%.99f", 1e4930) Roberto Ierusalimschy 2015-01-13 15:18:25 -02:00
  • ae27be40c9 better check for overflows in 'table.move' (removes restriction that initial position should be positive) Roberto Ierusalimschy 2015-01-13 14:27:29 -02:00
  • cdd26700e8 definition for 'MAXUPVAL' moved for a more "private" place and its value and comment corrected to reflect current implementation Roberto Ierusalimschy 2015-01-13 13:49:11 -02:00
  • a9a4bf68b0 typo in comment Roberto Ierusalimschy 2015-01-13 11:18:04 -02:00
  • f31cc8e342 typo in error message Roberto Ierusalimschy 2015-01-12 17:32:32 -02:00
  • 3c55790ebe 'setkey' -> 'setnodekey' (to avoid conflicts with POSIX) Roberto Ierusalimschy 2015-01-05 11:52:37 -02:00
  • 0adfa773b9 new macro 'cast_func' adds '__extension__' (in gnu compilers) when converting void* to function, to avoid warnings Roberto Ierusalimschy 2015-01-05 11:51:39 -02:00
  • 3317f5c6d9 includes 'stddef.h' (as it uses NULL) Roberto Ierusalimschy 2015-01-05 11:48:33 -02:00
  • dbf911c516 detail (added -Wconversion as a comment, to be used ocasionally) Roberto Ierusalimschy 2015-01-02 11:03:52 -02:00
  • 3a29087cb7 'lua_setlocal' should not pop value when failing (to be consistent with the manual and with 'lua_setupvalue') Roberto Ierusalimschy 2015-01-02 10:52:22 -02:00
  • 234fb7f695 clearer(?) code (also avoids a warning about 'c' being used without initialization) Roberto Ierusalimschy 2015-01-02 10:50:28 -02:00
  • c077d47465 does not define _XOPEN_SOURCE when LUA_USE_C89 is defined + defining _XOPEN_SOURCE==0 undefines that macro Roberto Ierusalimschy 2014-12-29 14:54:13 -02:00
  • 8e5290d81e all "divisions" (div,idiv,mod) by zero are not folded, to avoid problems during compilation + does not fold zero results, as they can collapse with -0.0 and the ANSI test to distinguish both needs a division by zero (which we are trying to avoid) + removed macro 'luai_numinvalidop' (as its main use case were divisions by zero) Roberto Ierusalimschy 2014-12-29 14:49:25 -02:00
  • a1c37f834a detail (macro 'luai_numidiv' uses 'luai_numdiv' to compute the division) Roberto Ierusalimschy 2014-12-29 11:27:55 -02:00
  • 1a7868c1d5 bug: 'random' limit is 2^31-1, not RAND_MAX Roberto Ierusalimschy 2014-12-27 18:32:26 -02:00
  • de3933480e details Roberto Ierusalimschy 2014-12-27 18:31:43 -02:00
  • 50e2eb8954 change in macro 'vmcase', avoding code inside it. (Code inside the macro harms tools such as debuggers.) Roberto Ierusalimschy 2014-12-27 18:30:38 -02:00
  • 94eb37dc73 new year (2015) Roberto Ierusalimschy 2014-12-26 15:24:27 -02:00
  • 900bdd5761 detail (to avoid warnings) Roberto Ierusalimschy 2014-12-26 12:46:07 -02:00
  • a51069202a removed macro 'luai_numinvalidop' (main motivation removed, as folding does not handle any division by zero by default) Roberto Ierusalimschy 2014-12-26 12:44:44 -02:00
  • fb6796ba06 removed useless initializations Roberto Ierusalimschy 2014-12-26 12:43:45 -02:00
  • 88ef06f4f3 comments were wrong (not updated about several changes) Roberto Ierusalimschy 2014-12-20 11:58:15 -02:00
  • eb45f3a9b6 details in 'luaM_reallocvchar' Roberto Ierusalimschy 2014-12-19 15:26:14 -02:00
  • 6321041058 new macro 'luaM_reallocvchar' to allocate arrays of chars (avoids uneeded tests and respective warnings) Roberto Ierusalimschy 2014-12-19 11:45:40 -02:00
  • 2b83711fba new macro 'nvalue' (to convert an object to a float when we know object is a number) Roberto Ierusalimschy 2014-12-19 11:36:32 -02:00
  • 3ae21a352c detail (in test for 'luai_numinvalidop', use a round float) Roberto Ierusalimschy 2014-12-19 11:33:06 -02:00
  • 570143bf88 comment Roberto Ierusalimschy 2014-12-19 11:31:12 -02:00
  • 1465edf341 old Visual Studio versions did not support 'noreturn' attribute Roberto Ierusalimschy 2014-12-19 11:30:23 -02:00
  • 77e786d436 stupid bug in T.stacklevel (not in use by the tests) Roberto Ierusalimschy 2014-12-18 10:13:42 -02:00
  • 6d79752e65 Windows uses 'long long' (instead of '__int64') when present; again, uses macro LLONG_MAX as a proxy for the support for 'long long'. Roberto Ierusalimschy 2014-12-16 15:17:30 -02:00
  • 75812a517b added macro LUA_USE_I64 for separate control of use of Windows-specific types Roberto Ierusalimschy 2014-12-16 14:20:01 -02:00
  • 151dc5cc5f traverse loaded modules (instead of globals) for a name for a function + removes prefix '_G.' from names (if present) Roberto Ierusalimschy 2014-12-14 16:32:26 -02:00
  • 0b6cfea005 comments Roberto Ierusalimschy 2014-12-13 15:57:00 -02:00
  • c8da3fbc35 in traceback names, give preference to 'name' over '_G.name' Roberto Ierusalimschy 2014-12-13 15:47:58 -02:00
  • c96cd1c647 reinsertion-control macro renamed: lconfig_h -> luaconf_h Roberto Ierusalimschy 2014-12-12 09:49:32 -02:00