1
0
mirror of https://github.com/lua/lua.git synced 2025-02-04 06:13:04 +08:00

3469 Commits

Author SHA1 Message Date
Roberto Ierusalimschy
cf22133b69 no need to avoid calling ctype functions as now they are implemented
by us (no inefficiencies due to accessing locale information)
2010-04-15 16:44:43 -03:00
Roberto Ierusalimschy
b7be05ad27 invalid instructions "cannot" happen 2010-04-15 16:43:43 -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
7dfa4cd655 first implementation of light C functions 2010-04-14 12:13:48 -03:00
Roberto Ierusalimschy
fc6203ee43 BUG: 'string.format' may get buffer when there are missing arguments 2010-04-12 13:13:02 -03:00
Roberto Ierusalimschy
b2dd246b7a better control in 'totalmem' over choosing counters 2010-04-12 13:07:39 -03:00
Roberto Ierusalimschy
d20ff60615 new macro LUA_NUMTAGS 2010-04-12 13:07:29 -03:00
Roberto Ierusalimschy
d41b467320 check memory allows strings to live in the main GC list (it should
work ok).
2010-04-12 09:42:07 -03:00
Roberto Ierusalimschy
4541243355 patterns now accept '\0' as a regular character 2010-04-12 09:00:50 -03:00
Roberto Ierusalimschy
9100f7479a new implementation for Generic Buffer manipulation (using userdata as
temporary buffer space)
2010-04-09 13:14:46 -03:00
Roberto Ierusalimschy
055104f5b6 keep memory-error message in the global state, so that its use
does not depend on Lua internalizing strings to avoid a string
creation on memory errors
2010-04-08 14:16:46 -03:00
Roberto Ierusalimschy
28aa733c15 macro 'eqstr' was being used to compare non-string entities 2010-04-08 14:06:33 -03:00
Roberto Ierusalimschy
6abde1b05a no need to keep "_ENV" name in global state (can be kept in lex state) 2010-04-05 13:35:37 -03:00
Roberto Ierusalimschy
d394d5536a new macro 'eqstr' 2010-04-05 13:26:37 -03:00
Roberto Ierusalimschy
a2f98314a3 'lua_pushstring' now uses 'luaS_new' 2010-04-05 11:21:38 -03:00
Roberto Ierusalimschy
a09c8d7beb cannot sweep main thread in sweepstring phase 2010-04-05 11:15:35 -03:00
Roberto Ierusalimschy
f80ff7a336 'luaS_new' changed from macro to function 2010-04-03 17:24:18 -03:00
Roberto Ierusalimschy
a08fc34ee4 avoid using 'luaS_new' when can use 'luaS_newlstr' 2010-04-02 12:39:07 -03:00
Roberto Ierusalimschy
d00d2eaf51 small changes in 'luaO_pushvfstring' 2010-04-02 12:30:27 -03:00
Roberto Ierusalimschy
11126422d9 option to return GC to normal (incremental, non generational) mode 2010-04-02 12:19:19 -03:00
Roberto Ierusalimschy
e54668b696 added proper code to trace garbage collection 2010-04-02 11:37:41 -03:00
Roberto Ierusalimschy
9eb832de54 work related to hooks moved from 'luaV_execute' to 'traceexec' 2010-03-29 17:45:49 -03:00
Roberto Ierusalimschy
82a1f5d354 comments 2010-03-29 14:44:31 -03:00
Roberto Ierusalimschy
a8d3aa14fd global table now is only kept in the registry 2010-03-29 14:43:14 -03:00
Roberto Ierusalimschy
064e406f67 no more fenvs! 2010-03-26 17:58:11 -03:00
Roberto Ierusalimschy
5c87f61e6b major collections in generational mode 2010-03-25 16:37:23 -03:00
Roberto Ierusalimschy
3aa9598177 'mainthread' is not inserted in the 'allgc' list anymore, but swept
separately.
2010-03-25 10:06:36 -03:00
Roberto Ierusalimschy
64d39ed1b6 generational mode no longer sweep old objects 2010-03-24 12:51:10 -03:00
Roberto Ierusalimschy
4433dbb5f5 userdata with finalizers are kept in a separated list ('udgc'), instead
of at the end of 'rootgc' (which was renamed to 'allgc', as it is not
"root" in the usual meaning for collectors)
2010-03-24 10:07:01 -03:00
Roberto Ierusalimschy
5cb128ea54 BUG: emergency collector might resize 'strt' (string table) when
creating a new string
+ atomic and markroot steps has some cost
+ full collection must leave collector in proper state when mode
is generational
2010-03-23 17:16:06 -03:00
Roberto Ierusalimschy
74123e9686 draft version of a generational mode for garbage collection. (Not well
tested; no major collections; ...)
2010-03-22 15:28:03 -03:00
Roberto Ierusalimschy
9c196bebad detail (wrong comment about LUAI_GCPAUSE) 2010-03-22 14:45:55 -03:00
Roberto Ierusalimschy
28b2566c97 'lua_assert' not visible from libraries 2010-03-22 14:28:31 -03:00
Roberto Ierusalimschy
caf74dd731 'cpcall' renamed to 'ccall' as it does not do a protected call 2010-03-19 18:04:17 -03:00
Roberto Ierusalimschy
62840c5fad 'ipairs' is deprecated 2010-03-19 12:52:48 -03:00
Roberto Ierusalimschy
5ca7cdd709 for compatibility only: 'module' changes the first upvalue of
calling function to affect its environment
2010-03-19 12:02:34 -03:00
Roberto Ierusalimschy
1514e49d43 avoid using function environments in C libraries (as it probably will
be deprecated)
2010-03-17 18:37:37 -03:00
Roberto Ierusalimschy
22ef84b6c8 '_ENV' name permanently stored in global state for easier access 2010-03-13 12:55:42 -03:00
Roberto Ierusalimschy
63a2b62468 must include 'string.h' because a macro uses 'strlen' 2010-03-13 12:55:01 -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
25c557ec63 first version of _ENV; no more global variables 2010-03-12 16:14:06 -03:00
Roberto Ierusalimschy
f292760f12 small optimization in luaL_addlstring (avoid adding chars one by one)
(suggested by Chuck Coffing)
2010-03-12 15:59:32 -03:00
Roberto Ierusalimschy
1124cb1247 first step towards _ENV: all chunks have an puvalues _ENV with the
global table
2010-03-08 13:55:52 -03:00
Roberto Ierusalimschy
c295147874 when finding a 'name' for a function, handle the case when the function
is a for iterator
2010-03-05 11:01:29 -03:00
Roberto Ierusalimschy
e560ac4862 when searching for a variable name, look existing upvalues before
goingg to upper levels
2010-03-04 15:12:57 -03:00
Roberto Ierusalimschy
915a9a912c just in case, better to flush error messages 2010-03-03 15:53:02 -03:00
Roberto Ierusalimschy
ae0a5e2142 new option '*L' for io.read + options for io.lines 2010-03-03 15:48:57 -03:00
Roberto Ierusalimschy
347f0c33d1 avoid 'continue' unless necessary 2010-02-27 18:16:24 -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
0fe2576a39 new instructions to optimize indexing on upvalues 2010-02-26 17:40:29 -03:00