Commit Graph

262 Commits

Author SHA1 Message Date
Roberto Ierusalimschy
4422b97472 keep 'luaL_checkversion_' with its signature in version 5.2, for
correct error messages in case of version mixings
2014-04-15 15:25:49 -03:00
Roberto Ierusalimschy
5aeb57f11f detail (error message for conversion from float to integer) 2014-04-01 15:55:06 -03:00
Roberto Ierusalimschy
a3addae036 lua_gettable and similars return type of gotten value 2014-03-12 17:57:40 -03:00
Roberto Ierusalimschy
a4c6dcf999 detail (better error messages for light userdata) 2014-02-19 10:48:53 -03:00
Roberto Ierusalimschy
4a1ed6e6e5 new field '__name' in metatables to help better error messages 2014-02-11 15:39:15 -02:00
Roberto Ierusalimschy
d438e1379d insertion of ".0" in floats with integer values done by "luaL_tolstring",
not by the core
2014-02-05 17:14:53 -02:00
Roberto Ierusalimschy
438c534ff4 'arg' arguments (previously called 'narg', 'nArg', 'numArg', etc.)
renamed all to 'arg'
2014-01-05 12:04:46 -02:00
Roberto Ierusalimschy
66d046833d no need to check "bad conversion number->int;" in luaL_checkversion,
as now Lua does not use tricks for the conversion, but there is a
need to check the sizes of number types, as they can be different
in two modules
2013-06-27 15:32:33 -03:00
Roberto Ierusalimschy
982aa7058f 'luaL_len' returns lua_Integer instead of 'int' 2013-06-25 11:05:26 -03:00
Roberto Ierusalimschy
c72fb1cf8e detail (removed 'assert') 2013-06-14 17:46:40 -03:00
Roberto Ierusalimschy
138e69cc55 correct error message for floating-point values out of (integer) range 2013-06-14 15:34:49 -03:00
Roberto Ierusalimschy
0394314c7a avoid using a negative value to test 'lua_tounsigned' 2013-06-14 15:12:53 -03:00
Roberto Ierusalimschy
6fb0b11350 string contatenation handles conversion of integers to strings +
floats always format as floats (with decimal dot or exponent)
2013-06-04 16:36:42 -03:00
Roberto Ierusalimschy
9c43d6a24e new format "%I" in 'lua_pushfstring' for lua_Integer 2013-04-25 10:53:13 -03:00
Roberto Ierusalimschy
af8efcc762 detail (avoid unnecessary "unconst" in cast) 2013-03-21 10:54:57 -03:00
Roberto Ierusalimschy
4082c77ff2 error message for 'bad self' includes original 'extramsg' 2012-10-19 12:55:01 -03:00
Roberto Ierusalimschy
7a3de1aba3 typo in comment 2012-09-24 19:57:26 -03:00
Roberto Ierusalimschy
c1a2a646c8 details (no need to use lua_pushfstring for plain strings) 2012-08-16 14:32:20 -03:00
Roberto Ierusalimschy
4dd0622d0c bug in luaL_getsubtable (calling lua_absindex not with original stack) 2012-05-31 17:28:45 -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
3e66d3b4be cleaner code (avoids loop with empty body) 2012-03-19 19:57:14 -03:00
Roberto Ierusalimschy
29a28693e5 'luaL_checkversion' called by 'luaL_setfuncs' 2012-03-18 13:52:49 -03:00
Roberto Ierusalimschy
e320b5b672 small bug: format '%d' for lua_Number argument 2011-12-06 14:33:55 -02:00
Roberto Ierusalimschy
e2feb886d6 macro 'luaL_getmetatable' seems more appropriate when getting
metatables in registry
2011-12-02 11:25:57 -02:00
Roberto Ierusalimschy
7bcb2462e4 comments 2011-11-30 10:58:57 -02:00
Roberto Ierusalimschy
3617e04e97 'lua_load' has an extra argument 'mode' 2011-11-29 13:55:08 -02:00
Roberto Ierusalimschy
6cce5c0601 new function 'luaL_loadfilex' 2011-11-14 15:10:24 -02:00
Roberto Ierusalimschy
eda87f1156 in 'luaL_checkstack', include extra stack space in test to allow
correct execution of error routines, if necessary
2011-11-09 17:08:55 -02:00
Roberto Ierusalimschy
2557107e91 removed unused variable 'found' (in 'findfield') + removed legacy
test for 'what' being "tail"
2011-07-25 14:18:49 -03:00
Roberto Ierusalimschy
470dd56a89 'os.execute' (and similars) should return 'exit' and code in case
of success, too.
2011-06-16 11:11:04 -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
2f128c5130 'luaL_setfuncs' does not need to accept a NULL list. (If there is
no list, there is no reason to call this function.)
2011-04-19 15:29:41 -03:00
Roberto Ierusalimschy
19fbdf6cae 'luaL_findtable' -> 'luaL_getsubtable' 2011-04-08 16:17:36 -03:00
Roberto Ierusalimschy
d806710ab5 returns for file-related functions and process-related functions
unified in 'auxlib'
2011-03-03 13:34:46 -03:00
Roberto Ierusalimschy
a10d495b18 'luaL_findtable' returns boolean about whether it created a new
table (to easy initializing table)
2011-01-10 13:51:42 -02:00
Roberto Ierusalimschy
c97aa9485c new function 'luaL_setmetatable' 2010-11-10 16:05:36 -02:00
Roberto Ierusalimschy
e885b91326 'luaL_typeerror' deprecated 2010-11-10 15:38:10 -02:00
Roberto Ierusalimschy
2a966116b1 detail (message) 2010-11-09 09:04:15 -02:00
Roberto Ierusalimschy
9be89a1864 'luaL_checkversion' also checks convertions (number to integer types) 2010-10-29 10:52:21 -02:00
Roberto Ierusalimschy
c6b64ffe65 new type lua_Unsigned and corresponding projection/injection functions 2010-10-25 18:31:11 -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
c3eb89544f 'luaL_loadlib' accepts Utf8 BOM in the beginning of files 2010-10-01 15:53:00 -03:00
Roberto Ierusalimschy
cd6c276e41 use index 0 for header of list of free references 2010-08-03 17:21:16 -03:00
Roberto Ierusalimschy
d447945685 'module'/'luaL_register' and associates are deprecated 2010-07-28 12:51:59 -03:00
Roberto Ierusalimschy
a9dc7c8828 functions lua_tonumber/lua_tointeger replaced by lua_tonumberx/lua_tointegerx
that have an extra out parameter with conversion status
2010-07-02 14:35:06 -03:00
Roberto Ierusalimschy
7192afafee new module policy: C modules do not create globals and do not register
themselves with 'require' (let 'require' do its work); new auxiliary
functions luaL_newlib/luaL_newlibtable/luaL_setfuncs/luaL_requiref.
Old luaL_register will be deprecated.
2010-07-02 08:38:13 -03:00
Roberto Ierusalimschy
a139e2e003 old (and complex) luaL_findtable now used only in compatibility code
inside lauxlib.c
2010-06-30 14:40:27 -03:00
Roberto Ierusalimschy
79f11fb2bb back with #-comments for binary files 2010-06-09 14:53:59 -03:00
Roberto Ierusalimschy
2c1a5d678d factoring out common code in 'module' and 'luaL_openlib' 2010-05-31 13:34:19 -03:00
Roberto Ierusalimschy
e8a2c36909 more comments 2010-05-18 14:32:19 -03:00