From 1b8b254a766350291f8e7e19feaf6326ebabe633 Mon Sep 17 00:00:00 2001 From: Luigi Scarso Date: Wed, 5 Sep 2018 21:30:41 +0000 Subject: sync with luatex revision 6924. git-svn-id: svn://tug.org/texlive/trunk@48591 c570f23f-e606-0410-a88d-b1316a301751 --- Build/source/libs/lua53/ChangeLog | 11 +++ Build/source/libs/lua53/Makefile.am | 1 + Build/source/libs/lua53/TLpatches/ChangeLog | 4 + Build/source/libs/lua53/TLpatches/patch-01-utf-8 | 17 +++- Build/source/libs/lua53/TLpatches/patch-02-FreeBSD | 6 +- Build/source/libs/lua53/TLpatches/patch-03-export | 14 +-- Build/source/libs/lua53/lua53-src/README | 2 +- .../source/libs/lua53/lua53-src/doc/contents.html | 6 +- Build/source/libs/lua53/lua53-src/doc/lua.css | 33 +++---- Build/source/libs/lua53/lua53-src/doc/manual.html | 101 ++++++++++----------- Build/source/libs/lua53/lua53-src/doc/readme.html | 6 +- Build/source/libs/lua53/lua53-src/src/Makefile | 4 +- Build/source/libs/lua53/lua53-src/src/lapi.c | 7 +- Build/source/libs/lua53/lua53-src/src/lapi.h | 2 +- Build/source/libs/lua53/lua53-src/src/lauxlib.c | 2 +- Build/source/libs/lua53/lua53-src/src/lauxlib.h | 2 +- Build/source/libs/lua53/lua53-src/src/lbaselib.c | 2 +- Build/source/libs/lua53/lua53-src/src/lbitlib.c | 2 +- Build/source/libs/lua53/lua53-src/src/lcode.c | 2 +- Build/source/libs/lua53/lua53-src/src/lcode.h | 2 +- Build/source/libs/lua53/lua53-src/src/lcorolib.c | 2 +- Build/source/libs/lua53/lua53-src/src/lctype.c | 2 +- Build/source/libs/lua53/lua53-src/src/lctype.h | 3 +- .../source/libs/lua53/lua53-src/src/lctype.h.orig | 2 +- Build/source/libs/lua53/lua53-src/src/ldblib.c | 2 +- Build/source/libs/lua53/lua53-src/src/ldebug.c | 3 +- Build/source/libs/lua53/lua53-src/src/ldebug.h | 2 +- Build/source/libs/lua53/lua53-src/src/ldo.c | 2 +- Build/source/libs/lua53/lua53-src/src/ldo.h | 2 +- Build/source/libs/lua53/lua53-src/src/ldump.c | 2 +- Build/source/libs/lua53/lua53-src/src/lfunc.c | 2 +- Build/source/libs/lua53/lua53-src/src/lfunc.h | 2 +- Build/source/libs/lua53/lua53-src/src/lgc.c | 5 +- Build/source/libs/lua53/lua53-src/src/lgc.h | 2 +- Build/source/libs/lua53/lua53-src/src/linit.c | 2 +- Build/source/libs/lua53/lua53-src/src/liolib.c | 13 ++- .../source/libs/lua53/lua53-src/src/liolib.c.orig | 13 ++- Build/source/libs/lua53/lua53-src/src/llex.c | 2 +- Build/source/libs/lua53/lua53-src/src/llex.h | 2 +- Build/source/libs/lua53/lua53-src/src/llimits.h | 2 +- Build/source/libs/lua53/lua53-src/src/lmathlib.c | 2 +- Build/source/libs/lua53/lua53-src/src/lmem.c | 2 +- Build/source/libs/lua53/lua53-src/src/lmem.h | 2 +- Build/source/libs/lua53/lua53-src/src/loadlib.c | 2 +- Build/source/libs/lua53/lua53-src/src/lobject.c | 5 +- Build/source/libs/lua53/lua53-src/src/lobject.h | 2 +- Build/source/libs/lua53/lua53-src/src/lopcodes.c | 2 +- Build/source/libs/lua53/lua53-src/src/lopcodes.h | 2 +- .../libs/lua53/lua53-src/src/lopcodes.h.orig | 2 +- Build/source/libs/lua53/lua53-src/src/loslib.c | 8 +- Build/source/libs/lua53/lua53-src/src/lparser.c | 4 +- Build/source/libs/lua53/lua53-src/src/lparser.h | 2 +- Build/source/libs/lua53/lua53-src/src/lprefix.h | 2 +- Build/source/libs/lua53/lua53-src/src/lstate.c | 2 +- Build/source/libs/lua53/lua53-src/src/lstate.h | 20 +++- Build/source/libs/lua53/lua53-src/src/lstring.c | 2 +- Build/source/libs/lua53/lua53-src/src/lstring.h | 2 +- Build/source/libs/lua53/lua53-src/src/lstrlib.c | 8 +- Build/source/libs/lua53/lua53-src/src/ltable.c | 35 +++++-- Build/source/libs/lua53/lua53-src/src/ltable.h | 4 +- Build/source/libs/lua53/lua53-src/src/ltablib.c | 2 +- Build/source/libs/lua53/lua53-src/src/ltm.c | 2 +- Build/source/libs/lua53/lua53-src/src/ltm.h | 2 +- Build/source/libs/lua53/lua53-src/src/lua.c | 4 +- Build/source/libs/lua53/lua53-src/src/lua.h | 8 +- Build/source/libs/lua53/lua53-src/src/luac.c | 5 +- Build/source/libs/lua53/lua53-src/src/luaconf.h | 11 ++- Build/source/libs/lua53/lua53-src/src/lualib.h | 2 +- Build/source/libs/lua53/lua53-src/src/lundump.c | 2 +- Build/source/libs/lua53/lua53-src/src/lundump.h | 2 +- .../source/libs/lua53/lua53-src/src/lundump.h.orig | 2 +- Build/source/libs/lua53/lua53-src/src/lutf8lib.c | 4 +- Build/source/libs/lua53/lua53-src/src/lvm.c | 2 +- Build/source/libs/lua53/lua53-src/src/lvm.h | 2 +- Build/source/libs/lua53/lua53-src/src/lzio.c | 2 +- Build/source/libs/lua53/lua53-src/src/lzio.h | 2 +- Build/source/libs/luajit/native/Makefile.am | 1 + Build/source/libs/zziplib/zziplib-src/zzip/lib.h | 1 + 78 files changed, 270 insertions(+), 189 deletions(-) (limited to 'Build/source/libs') diff --git a/Build/source/libs/lua53/ChangeLog b/Build/source/libs/lua53/ChangeLog index 8ef10ff28bb..d5c4b88bcd1 100644 --- a/Build/source/libs/lua53/ChangeLog +++ b/Build/source/libs/lua53/ChangeLog @@ -1,3 +1,14 @@ +2018-07-21 Luigi Scarso + + * Adapted for Lua 5.3.5 + + +2018-06-18 Luigi Scarso + + * dropped poppler, new pplib from + http://eurydyka.kaliope.org.pl/~pawel/libpp/html/ppapi.html + + 2017-10-24 Luigi Scarso * Adapted for Lua 5.3.4 diff --git a/Build/source/libs/lua53/Makefile.am b/Build/source/libs/lua53/Makefile.am index a7994ea5a39..f736ce9a328 100644 --- a/Build/source/libs/lua53/Makefile.am +++ b/Build/source/libs/lua53/Makefile.am @@ -65,6 +65,7 @@ nodist_libtexlua53_la_SOURCES = \ @LUA53_TREE@/src/lvm.c \ @LUA53_TREE@/src/lzio.c + lua53includedir = ${includedir}/texlua53 lua53include_HEADERS = \ diff --git a/Build/source/libs/lua53/TLpatches/ChangeLog b/Build/source/libs/lua53/TLpatches/ChangeLog index 882ddcdde9e..dd2bcb2f07b 100644 --- a/Build/source/libs/lua53/TLpatches/ChangeLog +++ b/Build/source/libs/lua53/TLpatches/ChangeLog @@ -1,3 +1,7 @@ +2018-07-21 Luigi Scarso + Adapted for lua 5.3.5 + + 2017-10-24 Luigi Scarso Adapted for lua 5.3.4 diff --git a/Build/source/libs/lua53/TLpatches/patch-01-utf-8 b/Build/source/libs/lua53/TLpatches/patch-01-utf-8 index f2ac4013430..0f7cb898128 100644 --- a/Build/source/libs/lua53/TLpatches/patch-01-utf-8 +++ b/Build/source/libs/lua53/TLpatches/patch-01-utf-8 @@ -1,7 +1,16 @@ -diff -ur lua-5.3.4.orig/src/lctype.h lua-5.3.4/src/lctype.h ---- lctype.h.orig 2017-10-24 15:14:50.724139638 +0200 -+++ lctype.h 2017-10-24 15:15:51.704137138 +0200 -@@ -53,9 +53,11 @@ +diff -u lctype.h.orig lctype.h +--- lctype.h.orig 2018-07-21 09:57:36.061692228 +0200 ++++ lctype.h 2018-07-21 10:03:29.625677730 +0200 +@@ -7,6 +7,8 @@ + #ifndef lctype_h + #define lctype_h + ++#include ++ + #include "lua.h" + + +@@ -53,9 +55,11 @@ /* ** 'lalpha' (Lua alphabetic) and 'lalnum' (Lua alphanumeric) both include '_' diff --git a/Build/source/libs/lua53/TLpatches/patch-02-FreeBSD b/Build/source/libs/lua53/TLpatches/patch-02-FreeBSD index fc59f4842a3..ad85a5988d8 100644 --- a/Build/source/libs/lua53/TLpatches/patch-02-FreeBSD +++ b/Build/source/libs/lua53/TLpatches/patch-02-FreeBSD @@ -1,6 +1,6 @@ -diff -ur liolib.c.orig liolib.c ---- liolib.c.orig 2017-10-24 15:16:06.036136550 +0200 -+++ liolib.c 2017-10-24 15:16:49.968134748 +0200 +diff -u liolib.c.orig liolib.c +--- liolib.c.orig 2017-04-19 19:29:57.000000000 +0200 ++++ liolib.c 2018-07-21 10:04:50.965674394 +0200 @@ -16,6 +16,9 @@ #include #include diff --git a/Build/source/libs/lua53/TLpatches/patch-03-export b/Build/source/libs/lua53/TLpatches/patch-03-export index dda2b87b24c..9bc2a4627fc 100644 --- a/Build/source/libs/lua53/TLpatches/patch-03-export +++ b/Build/source/libs/lua53/TLpatches/patch-03-export @@ -1,6 +1,6 @@ -diff -ur lopcodes.h.orig lopcodes.h ---- lopcodes.h.orig 2017-10-24 15:22:51.012119943 +0200 -+++ lopcodes.h 2017-10-24 15:18:37.924130321 +0200 +diff -u lopcodes.h.orig lopcodes.h +--- lopcodes.h.orig 2018-07-21 09:59:37.349687255 +0200 ++++ lopcodes.h 2018-07-21 10:07:04.413668921 +0200 @@ -278,7 +278,7 @@ OpArgK /* argument is a constant or register/constant */ }; @@ -20,9 +20,10 @@ diff -ur lopcodes.h.orig lopcodes.h /* number of list items to accumulate before a SETLIST instruction */ -diff -ur lundump.h.orig lundump.h ---- lundump.h.orig 2017-10-24 15:19:03.860129258 +0200 -+++ lundump.h 2017-10-24 15:19:47.088127485 +0200 + +diff -u lundump.h.orig lundump.h +--- lundump.h.orig 2018-07-21 10:00:01.545686262 +0200 ++++ lundump.h 2018-07-21 10:08:12.341666136 +0200 @@ -26,7 +26,7 @@ LUAI_FUNC LClosure* luaU_undump (lua_State* L, ZIO* Z, const char* name); @@ -32,4 +33,3 @@ diff -ur lundump.h.orig lundump.h void* data, int strip); #endif - diff --git a/Build/source/libs/lua53/lua53-src/README b/Build/source/libs/lua53/lua53-src/README index 0b31908a06c..ed424defe02 100644 --- a/Build/source/libs/lua53/lua53-src/README +++ b/Build/source/libs/lua53/lua53-src/README @@ -1,5 +1,5 @@ -This is Lua 5.3.4, released on 12 Jan 2017. +This is Lua 5.3.5, released on 26 Jun 2018. For installation instructions, license details, and further information about Lua, see doc/readme.html. diff --git a/Build/source/libs/lua53/lua53-src/doc/contents.html b/Build/source/libs/lua53/lua53-src/doc/contents.html index 445556f9641..c4eb2677906 100644 --- a/Build/source/libs/lua53/lua53-src/doc/contents.html +++ b/Build/source/libs/lua53/lua53-src/doc/contents.html @@ -32,7 +32,7 @@ For a complete introduction to Lua programming, see the book

-Copyright © 2015–2017 Lua.org, PUC-Rio. +Copyright © 2015–2018 Lua.org, PUC-Rio. Freely available under the terms of the Lua license. @@ -609,10 +609,10 @@ Freely available under the terms of the

diff --git a/Build/source/libs/lua53/lua53-src/doc/lua.css b/Build/source/libs/lua53/lua53-src/doc/lua.css index 5bedf7eb898..cbd0799d152 100644 --- a/Build/source/libs/lua53/lua53-src/doc/lua.css +++ b/Build/source/libs/lua53/lua53-src/doc/lua.css @@ -10,7 +10,7 @@ body { line-height: 1.25 ; margin: 16px auto ; padding: 32px ; - border: solid #a0a0a0 1px ; + border: solid #ccc 1px ; border-radius: 20px ; max-width: 70em ; width: 90% ; @@ -111,36 +111,29 @@ pre.session { border-radius: 8px ; } -td.gutter { - width: 4% ; -} - -table.columns { +table { border: none ; border-spacing: 0 ; border-collapse: collapse ; } -table.columns td { - vertical-align: top ; +td { padding: 0 ; - padding-bottom: 1em ; - text-align: justify ; - line-height: 1.25 ; + margin: 0 ; } -p.logos a:link:hover, p.logos a:visited:hover { - background-color: inherit ; +td.gutter { + width: 4% ; } -table.book { - border: none ; - border-spacing: 0 ; - border-collapse: collapse ; +table.columns td { + vertical-align: top ; + padding-bottom: 1em ; + text-align: justify ; + line-height: 1.25 ; } table.book td { - padding: 0 ; vertical-align: top ; } @@ -159,6 +152,10 @@ table.book span { margin-top: 0.25em ; } +p.logos a:link:hover, p.logos a:visited:hover { + background-color: inherit ; +} + img { background-color: white ; } diff --git a/Build/source/libs/lua53/lua53-src/doc/manual.html b/Build/source/libs/lua53/lua53-src/doc/manual.html index 3126b5d6afb..89a642a45d9 100644 --- a/Build/source/libs/lua53/lua53-src/doc/manual.html +++ b/Build/source/libs/lua53/lua53-src/doc/manual.html @@ -19,7 +19,7 @@ by Roberto Ierusalimschy, Luiz Henrique de Figueiredo, Waldemar Celes

-Copyright © 2015–2017 Lua.org, PUC-Rio. +Copyright © 2015–2018 Lua.org, PUC-Rio. Freely available under the terms of the Lua license. @@ -35,7 +35,7 @@ Freely available under the terms of the

- + @@ -203,8 +203,8 @@ even those that do not support threads natively.

The type table implements associative arrays, -that is, arrays that can be indexed not only with numbers, -but with any Lua value except nil and NaN. +that is, arrays that can have as indices not only numbers, +but any Lua value except nil and NaN. (Not a Number is a special value used to represent undefined or unrepresentable numerical results, such as 0/0.) Tables can be heterogeneous; @@ -400,6 +400,8 @@ with the event name prefixed by two underscores; the corresponding values are called metamethods. In the previous example, the key is "__add" and the metamethod is the function that performs the addition. +Unless stated otherwise, +metamethods should be function values.

@@ -597,7 +599,7 @@ it is also slower than a real __le metamethod.)

  • __index: -The indexing access table[key]. +The indexing access operation table[key]. This event happens when table is not a table or when key is not present in table. The metamethod is looked up in table. @@ -1276,13 +1278,8 @@ Square brackets are used to index a table:
     	var ::= prefixexp ‘[’ exp ‘]

    -The meaning of accesses to table fields can be changed via metatables. -An access to an indexed variable t[i] is equivalent to -a call gettable_event(t,i). -(See §2.4 for a complete description of the -gettable_event function. -This function is not defined or callable in Lua. -We use it here only for explanatory purposes.) +The meaning of accesses to table fields can be changed via metatables +(see §2.4).

    @@ -1476,23 +1473,18 @@ and cyclically permutes the values of x, y, and z. -

    -The meaning of assignments to global variables -and table fields can be changed via metatables. -An assignment to an indexed variable t[i] = val is equivalent to -settable_event(t,i,val). -(See §2.4 for a complete description of the -settable_event function. -This function is not defined or callable in Lua. -We use it here only for explanatory purposes.) - -

    An assignment to a global name x = val is equivalent to the assignment _ENV.x = val (see §2.2). +

    +The meaning of assignments to table fields and +global variables (which are actually table fields, too) +can be changed via metatables (see §2.4). + + @@ -1831,17 +1823,17 @@ Here are some examples: g(f(), x) -- f() is adjusted to 1 result g(x, f()) -- g gets x plus all results from f() a,b,c = f(), x -- f() is adjusted to 1 result (c gets nil) - a,b = ... -- a gets the first vararg parameter, b gets + a,b = ... -- a gets the first vararg argument, b gets -- the second (both a and b can get nil if there - -- is no corresponding vararg parameter) + -- is no corresponding vararg argument) a,b,c = x, f() -- f() is adjusted to 2 results a,b,c = f() -- f() is adjusted to 3 results return f() -- returns all results from f() - return ... -- returns all received vararg parameters + return ... -- returns all received vararg arguments return x,y,f() -- returns x, y, and all results from f() {f()} -- creates a list with all results from f() - {...} -- creates a list with all vararg parameters + {...} -- creates a list with all vararg arguments {f(), nil} -- f() is adjusted to 1 result @@ -2039,9 +2031,12 @@ two objects are considered equal only if they are the same object. Every time you create a new object (a table, userdata, or thread), this new object is different from any previously existing object. -Closures with the same reference are always equal. +A closure is always equal to itself. Closures with any detectable difference (different behavior, different definition) are always different. +Closures created at different times but with no detectable differences +may be classified as equal or not +(depending on internal caching details).

    @@ -2303,7 +2298,7 @@ If the value of prefixexp has type function, then this function is called with the given arguments. Otherwise, the prefixexp "call" metamethod is called, -having as first parameter the value of prefixexp, +having as first argument the value of prefixexp, followed by the original call arguments (see §2.4). @@ -2881,7 +2876,7 @@ it can do whatever it wants on that Lua state, as it should be already protected. However, when C code operates on other Lua states -(e.g., a Lua parameter to the function, +(e.g., a Lua argument to the function, a Lua state stored in the registry, or the result of lua_newthread), it should use them only in API calls that cannot raise errors. @@ -3370,7 +3365,7 @@ it is left unchanged. Destroys all objects in the given Lua state (calling the corresponding garbage-collection metamethods, if any) and frees all dynamic memory used by this state. -On several platforms, you may not need to call this function, +In several platforms, you may not need to call this function, because all resources are naturally released when the host program ends. On the other hand, long-running programs that create multiple states, such as daemons or web servers, @@ -5584,7 +5579,7 @@ given as argument to a hook (see lua_Hook).

    -To get information about a function you push it onto the stack +To get information about a function, you push it onto the stack and start the what string with the character '>'. (In that case, lua_getinfo pops the function from the top of the stack.) @@ -6462,7 +6457,7 @@ file-related functions in the standard library

    Pushes onto the stack the field e from the metatable -of the object at index obj and returns the type of pushed value. +of the object at index obj and returns the type of the pushed value. If the object does not have a metatable, or if the metatable does not have this field, pushes nothing and returns LUA_TNIL. @@ -6749,7 +6744,7 @@ In words, if the argument arg is nil or absent, the macro results in the default dflt. Otherwise, it results in the result of calling func with the state L and the argument index arg as -parameters. +arguments. Note that it evaluates the expression dflt only if needed. @@ -8680,7 +8675,7 @@ the lowercase letters plus the '-' character.

    You can put a closing square bracket in a set by positioning it as the first character in the set. -You can put an hyphen in a set +You can put a hyphen in a set by positioning it as the first or the last character in the set. (You can also use an escape for both cases.) @@ -9082,8 +9077,8 @@ Returns the destination table a2.

    -Returns a new table with all parameters stored into keys 1, 2, etc. -and with a field "n" with the total number of parameters. +Returns a new table with all arguments stored into keys 1, 2, etc. +and with a field "n" with the total number of arguments. Note that the resulting table may not be a sequence. @@ -9215,7 +9210,7 @@ Returns the arc sine of x (in radians).

    Returns the arc tangent of y/x (in radians), -but uses the signs of both parameters to find the +but uses the signs of both arguments to find the quadrant of the result. (It also handles correctly the case of x being zero.) @@ -9516,7 +9511,7 @@ all I/O functions return nil on failure (plus an error message as a second result and a system-dependent error code as a third result) and some value different from nil on success. -On non-POSIX systems, +In non-POSIX systems, the computation of the error message and error code in case of errors may be not thread safe, @@ -9553,7 +9548,7 @@ When called with a file name, it opens the named file (in text mode), and sets its handle as the default input file. When called with a file handle, it simply sets this file handle as the default input file. -When called without parameters, +When called without arguments, it returns the current default input file. @@ -9580,7 +9575,7 @@ it returns no values (to finish the loop) and automatically closes the file. The call io.lines() (with no file name) is equivalent to io.input():lines("*l"); that is, it iterates over the lines of the default input file. -In this case it does not close the file when the loop ends. +In this case, the iterator does not close the file when the loop ends.

    @@ -9963,7 +9958,7 @@ the host system and on the current locale.

    -On non-POSIX systems, +In non-POSIX systems, this function may be not thread safe because of its reliance on C function gmtime and C function localtime. @@ -10163,7 +10158,7 @@ and explicitly removed when no longer needed.

    -On POSIX systems, +In POSIX systems, this function also creates a file with that name, to avoid security risks. (Someone else might create the file with wrong permissions @@ -10301,8 +10296,8 @@ The first parameter or local variable has index 1, and so on, following the order that they are declared in the code, counting only the variables that are active in the current scope of the function. -Negative indices refer to vararg parameters; --1 is the first vararg parameter. +Negative indices refer to vararg arguments; +-1 is the first vararg argument. The function returns nil if there is no variable with the given index, and raises an error when called with a level out of range. (You can call debug.getinfo to check whether the level is valid.) @@ -10400,7 +10395,7 @@ When called without arguments,

    -When the hook is called, its first parameter is a string +When the hook is called, its first argument is a string describing the event that has triggered its call: "call" (or "tail call"), "return", @@ -10551,7 +10546,8 @@ The options are:

    • -e stat: executes string stat;
    • -
    • -l mod: "requires" mod;
    • +
    • -l mod: "requires" mod and assigns the + result to global @mod;
    • -i: enters interactive mode after running script;
    • -v: prints version information;
    • -E: ignores environment variables;
    • @@ -10629,7 +10625,7 @@ For instance, the call

      will print "-e". If there is a script, -the script is called with parameters +the script is called with arguments arg[1], ···, arg[#arg]. (Like all chunks in Lua, the script is compiled as a vararg function.) @@ -10815,7 +10811,7 @@ The following functions were deprecated in the mathematical library: frexp, and ldexp. You can replace math.pow(x,y) with x^y; you can replace math.atan2 with math.atan, -which now accepts one or two parameters; +which now accepts one or two arguments; you can replace math.ldexp(x,exp) with x * 2.0^exp. For the other operations, you can either use an external library or @@ -10850,7 +10846,7 @@ of the first result.)

      • -Continuation functions now receive as parameters what they needed +Continuation functions now receive as arguments what they needed to get through lua_getctx, so lua_getctx has been removed. Adapt your code accordingly. @@ -10973,12 +10969,13 @@ and LiteralString, see §3.1.) + diff --git a/Build/source/libs/lua53/lua53-src/doc/readme.html b/Build/source/libs/lua53/lua53-src/doc/readme.html index 96a9386e2af..b118f7b02d1 100644 --- a/Build/source/libs/lua53/lua53-src/doc/readme.html +++ b/Build/source/libs/lua53/lua53-src/doc/readme.html @@ -107,7 +107,7 @@ Here are the details.
        1. Open a terminal window and move to -the top-level directory, which is named lua-5.3.x. +the top-level directory, which is named lua-5.3.5. The Makefile there controls both the build process and the installation process.

        2. @@ -355,10 +355,10 @@ THE SOFTWARE. diff --git a/Build/source/libs/lua53/lua53-src/src/Makefile b/Build/source/libs/lua53/lua53-src/src/Makefile index d71c75c8732..64c78f775ba 100644 --- a/Build/source/libs/lua53/lua53-src/src/Makefile +++ b/Build/source/libs/lua53/lua53-src/src/Makefile @@ -102,7 +102,7 @@ c89: freebsd: - $(MAKE) $(ALL) SYSCFLAGS="-DLUA_USE_LINUX" SYSLIBS="-Wl,-E -lreadline" + $(MAKE) $(ALL) SYSCFLAGS="-DLUA_USE_LINUX -DLUA_USE_READLINE -I/usr/include/edit" SYSLIBS="-Wl,-E -ledit" CC="cc" generic: $(ALL) @@ -110,7 +110,7 @@ linux: $(MAKE) $(ALL) SYSCFLAGS="-DLUA_USE_LINUX" SYSLIBS="-Wl,-E -ldl -lreadline" macosx: - $(MAKE) $(ALL) SYSCFLAGS="-DLUA_USE_MACOSX" SYSLIBS="-lreadline" CC=cc + $(MAKE) $(ALL) SYSCFLAGS="-DLUA_USE_MACOSX" SYSLIBS="-lreadline" mingw: $(MAKE) "LUA_A=lua53.dll" "LUA_T=lua.exe" \ diff --git a/Build/source/libs/lua53/lua53-src/src/lapi.c b/Build/source/libs/lua53/lua53-src/src/lapi.c index c9455a5d8cd..02b7fab7ead 100644 --- a/Build/source/libs/lua53/lua53-src/src/lapi.c +++ b/Build/source/libs/lua53/lua53-src/src/lapi.c @@ -1,5 +1,5 @@ /* -** $Id: lapi.c,v 2.259 2016/02/29 14:27:14 roberto Exp $ +** $Id: lapi.c,v 2.259.1.2 2017/12/06 18:35:12 roberto Exp $ ** Lua API ** See Copyright Notice in lua.h */ @@ -533,6 +533,7 @@ LUA_API void lua_pushcclosure (lua_State *L, lua_CFunction fn, int n) { lua_lock(L); if (n == 0) { setfvalue(L->top, fn); + api_incr_top(L); } else { CClosure *cl; @@ -546,9 +547,9 @@ LUA_API void lua_pushcclosure (lua_State *L, lua_CFunction fn, int n) { /* does not need barrier because closure is white */ } setclCvalue(L, L->top, cl); + api_incr_top(L); + luaC_checkGC(L); } - api_incr_top(L); - luaC_checkGC(L); lua_unlock(L); } diff --git a/Build/source/libs/lua53/lua53-src/src/lapi.h b/Build/source/libs/lua53/lua53-src/src/lapi.h index 6d36dee3fb7..8e16ad53d99 100644 --- a/Build/source/libs/lua53/lua53-src/src/lapi.h +++ b/Build/source/libs/lua53/lua53-src/src/lapi.h @@ -1,5 +1,5 @@ /* -** $Id: lapi.h,v 2.9 2015/03/06 19:49:50 roberto Exp $ +** $Id: lapi.h,v 2.9.1.1 2017/04/19 17:20:42 roberto Exp $ ** Auxiliary functions from Lua API ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lauxlib.c b/Build/source/libs/lua53/lua53-src/src/lauxlib.c index f7a383663e1..8bdada50a7e 100644 --- a/Build/source/libs/lua53/lua53-src/src/lauxlib.c +++ b/Build/source/libs/lua53/lua53-src/src/lauxlib.c @@ -1,5 +1,5 @@ /* -** $Id: lauxlib.c,v 1.289 2016/12/20 18:37:00 roberto Exp $ +** $Id: lauxlib.c,v 1.289.1.1 2017/04/19 17:20:42 roberto Exp $ ** Auxiliary functions for building Lua libraries ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lauxlib.h b/Build/source/libs/lua53/lua53-src/src/lauxlib.h index 9a2e66aa067..9857d3a835a 100644 --- a/Build/source/libs/lua53/lua53-src/src/lauxlib.h +++ b/Build/source/libs/lua53/lua53-src/src/lauxlib.h @@ -1,5 +1,5 @@ /* -** $Id: lauxlib.h,v 1.131 2016/12/06 14:54:31 roberto Exp $ +** $Id: lauxlib.h,v 1.131.1.1 2017/04/19 17:20:42 roberto Exp $ ** Auxiliary functions for building Lua libraries ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lbaselib.c b/Build/source/libs/lua53/lua53-src/src/lbaselib.c index 08523e6e754..6460e4f8d42 100644 --- a/Build/source/libs/lua53/lua53-src/src/lbaselib.c +++ b/Build/source/libs/lua53/lua53-src/src/lbaselib.c @@ -1,5 +1,5 @@ /* -** $Id: lbaselib.c,v 1.314 2016/09/05 19:06:34 roberto Exp $ +** $Id: lbaselib.c,v 1.314.1.1 2017/04/19 17:39:34 roberto Exp $ ** Basic library ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lbitlib.c b/Build/source/libs/lua53/lua53-src/src/lbitlib.c index 1cb1d5b9323..4786c0d4830 100644 --- a/Build/source/libs/lua53/lua53-src/src/lbitlib.c +++ b/Build/source/libs/lua53/lua53-src/src/lbitlib.c @@ -1,5 +1,5 @@ /* -** $Id: lbitlib.c,v 1.30 2015/11/11 19:08:09 roberto Exp $ +** $Id: lbitlib.c,v 1.30.1.1 2017/04/19 17:20:42 roberto Exp $ ** Standard library for bitwise operations ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lcode.c b/Build/source/libs/lua53/lua53-src/src/lcode.c index 0bb414262e3..12619f54a02 100644 --- a/Build/source/libs/lua53/lua53-src/src/lcode.c +++ b/Build/source/libs/lua53/lua53-src/src/lcode.c @@ -1,5 +1,5 @@ /* -** $Id: lcode.c,v 2.112 2016/12/22 13:08:50 roberto Exp $ +** $Id: lcode.c,v 2.112.1.1 2017/04/19 17:20:42 roberto Exp $ ** Code generator for Lua ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lcode.h b/Build/source/libs/lua53/lua53-src/src/lcode.h index cd306d573ae..882dc9c156e 100644 --- a/Build/source/libs/lua53/lua53-src/src/lcode.h +++ b/Build/source/libs/lua53/lua53-src/src/lcode.h @@ -1,5 +1,5 @@ /* -** $Id: lcode.h,v 1.64 2016/01/05 16:22:37 roberto Exp $ +** $Id: lcode.h,v 1.64.1.1 2017/04/19 17:20:42 roberto Exp $ ** Code generator for Lua ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lcorolib.c b/Build/source/libs/lua53/lua53-src/src/lcorolib.c index 2303429e7bb..0b17af9e343 100644 --- a/Build/source/libs/lua53/lua53-src/src/lcorolib.c +++ b/Build/source/libs/lua53/lua53-src/src/lcorolib.c @@ -1,5 +1,5 @@ /* -** $Id: lcorolib.c,v 1.10 2016/04/11 19:19:55 roberto Exp $ +** $Id: lcorolib.c,v 1.10.1.1 2017/04/19 17:20:42 roberto Exp $ ** Coroutine Library ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lctype.c b/Build/source/libs/lua53/lua53-src/src/lctype.c index ae9367e691b..f8ad7a2edf6 100644 --- a/Build/source/libs/lua53/lua53-src/src/lctype.c +++ b/Build/source/libs/lua53/lua53-src/src/lctype.c @@ -1,5 +1,5 @@ /* -** $Id: lctype.c,v 1.12 2014/11/02 19:19:04 roberto Exp $ +** $Id: lctype.c,v 1.12.1.1 2017/04/19 17:20:42 roberto Exp $ ** 'ctype' functions for Lua ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lctype.h b/Build/source/libs/lua53/lua53-src/src/lctype.h index b961175bc42..a963eb9015f 100644 --- a/Build/source/libs/lua53/lua53-src/src/lctype.h +++ b/Build/source/libs/lua53/lua53-src/src/lctype.h @@ -1,5 +1,5 @@ /* -** $Id: lctype.h,v 1.12 2011/07/15 12:50:29 roberto Exp $ +** $Id: lctype.h,v 1.12.1.1 2013/04/12 18:48:47 roberto Exp $ ** 'ctype' functions for Lua ** See Copyright Notice in lua.h */ @@ -76,6 +76,7 @@ LUAI_DDEC const lu_byte luai_ctype_[UCHAR_MAX + 2]; #else /* }{ */ + /* ** use standard C ctypes */ diff --git a/Build/source/libs/lua53/lua53-src/src/lctype.h.orig b/Build/source/libs/lua53/lua53-src/src/lctype.h.orig index 99c7d122376..b09b21a337c 100644 --- a/Build/source/libs/lua53/lua53-src/src/lctype.h.orig +++ b/Build/source/libs/lua53/lua53-src/src/lctype.h.orig @@ -1,5 +1,5 @@ /* -** $Id: lctype.h,v 1.12 2011/07/15 12:50:29 roberto Exp $ +** $Id: lctype.h,v 1.12.1.1 2013/04/12 18:48:47 roberto Exp $ ** 'ctype' functions for Lua ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/ldblib.c b/Build/source/libs/lua53/lua53-src/src/ldblib.c index 786f6cd95d7..9d29afb0a89 100644 --- a/Build/source/libs/lua53/lua53-src/src/ldblib.c +++ b/Build/source/libs/lua53/lua53-src/src/ldblib.c @@ -1,5 +1,5 @@ /* -** $Id: ldblib.c,v 1.151 2015/11/23 11:29:43 roberto Exp $ +** $Id: ldblib.c,v 1.151.1.1 2017/04/19 17:20:42 roberto Exp $ ** Interface from Lua to its debug API ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/ldebug.c b/Build/source/libs/lua53/lua53-src/src/ldebug.c index 239affb76c5..e1389296e9e 100644 --- a/Build/source/libs/lua53/lua53-src/src/ldebug.c +++ b/Build/source/libs/lua53/lua53-src/src/ldebug.c @@ -1,5 +1,5 @@ /* -** $Id: ldebug.c,v 2.121 2016/10/19 12:32:10 roberto Exp $ +** $Id: ldebug.c,v 2.121.1.2 2017/07/10 17:21:50 roberto Exp $ ** Debug Interface ** See Copyright Notice in lua.h */ @@ -653,6 +653,7 @@ l_noret luaG_runerror (lua_State *L, const char *fmt, ...) { CallInfo *ci = L->ci; const char *msg; va_list argp; + luaC_checkGC(L); /* error message uses memory */ va_start(argp, fmt); msg = luaO_pushvfstring(L, fmt, argp); /* format message */ va_end(argp); diff --git a/Build/source/libs/lua53/lua53-src/src/ldebug.h b/Build/source/libs/lua53/lua53-src/src/ldebug.h index 0e31546b1b4..8cea0ee0a72 100644 --- a/Build/source/libs/lua53/lua53-src/src/ldebug.h +++ b/Build/source/libs/lua53/lua53-src/src/ldebug.h @@ -1,5 +1,5 @@ /* -** $Id: ldebug.h,v 2.14 2015/05/22 17:45:56 roberto Exp $ +** $Id: ldebug.h,v 2.14.1.1 2017/04/19 17:20:42 roberto Exp $ ** Auxiliary functions from Debug Interface module ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/ldo.c b/Build/source/libs/lua53/lua53-src/src/ldo.c index 90b695fb04c..316e45c8fec 100644 --- a/Build/source/libs/lua53/lua53-src/src/ldo.c +++ b/Build/source/libs/lua53/lua53-src/src/ldo.c @@ -1,5 +1,5 @@ /* -** $Id: ldo.c,v 2.157 2016/12/13 15:52:21 roberto Exp $ +** $Id: ldo.c,v 2.157.1.1 2017/04/19 17:20:42 roberto Exp $ ** Stack and Call structure of Lua ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/ldo.h b/Build/source/libs/lua53/lua53-src/src/ldo.h index 4f5d51c3c70..3b2983a3864 100644 --- a/Build/source/libs/lua53/lua53-src/src/ldo.h +++ b/Build/source/libs/lua53/lua53-src/src/ldo.h @@ -1,5 +1,5 @@ /* -** $Id: ldo.h,v 2.29 2015/12/21 13:02:14 roberto Exp $ +** $Id: ldo.h,v 2.29.1.1 2017/04/19 17:20:42 roberto Exp $ ** Stack and Call structure of Lua ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/ldump.c b/Build/source/libs/lua53/lua53-src/src/ldump.c index 016e300822f..f025acac3c2 100644 --- a/Build/source/libs/lua53/lua53-src/src/ldump.c +++ b/Build/source/libs/lua53/lua53-src/src/ldump.c @@ -1,5 +1,5 @@ /* -** $Id: ldump.c,v 2.37 2015/10/08 15:53:49 roberto Exp $ +** $Id: ldump.c,v 2.37.1.1 2017/04/19 17:20:42 roberto Exp $ ** save precompiled Lua chunks ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lfunc.c b/Build/source/libs/lua53/lua53-src/src/lfunc.c index 67967dab3fc..ccafbb8ab3c 100644 --- a/Build/source/libs/lua53/lua53-src/src/lfunc.c +++ b/Build/source/libs/lua53/lua53-src/src/lfunc.c @@ -1,5 +1,5 @@ /* -** $Id: lfunc.c,v 2.45 2014/11/02 19:19:04 roberto Exp $ +** $Id: lfunc.c,v 2.45.1.1 2017/04/19 17:39:34 roberto Exp $ ** Auxiliary functions to manipulate prototypes and closures ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lfunc.h b/Build/source/libs/lua53/lua53-src/src/lfunc.h index 2eeb0d5a489..c916e9878ad 100644 --- a/Build/source/libs/lua53/lua53-src/src/lfunc.h +++ b/Build/source/libs/lua53/lua53-src/src/lfunc.h @@ -1,5 +1,5 @@ /* -** $Id: lfunc.h,v 2.15 2015/01/13 15:49:11 roberto Exp $ +** $Id: lfunc.h,v 2.15.1.1 2017/04/19 17:39:34 roberto Exp $ ** Auxiliary functions to manipulate prototypes and closures ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lgc.c b/Build/source/libs/lua53/lua53-src/src/lgc.c index ba2c19e14e9..db4df82922e 100644 --- a/Build/source/libs/lua53/lua53-src/src/lgc.c +++ b/Build/source/libs/lua53/lua53-src/src/lgc.c @@ -1,5 +1,5 @@ /* -** $Id: lgc.c,v 2.215 2016/12/22 13:08:50 roberto Exp $ +** $Id: lgc.c,v 2.215.1.2 2017/08/31 16:15:27 roberto Exp $ ** Garbage Collector ** See Copyright Notice in lua.h */ @@ -643,8 +643,9 @@ static void clearkeys (global_State *g, GCObject *l, GCObject *f) { for (n = gnode(h, 0); n < limit; n++) { if (!ttisnil(gval(n)) && (iscleared(g, gkey(n)))) { setnilvalue(gval(n)); /* remove value ... */ - removeentry(n); /* and remove entry from table */ } + if (ttisnil(gval(n))) /* is entry empty? */ + removeentry(n); /* remove entry from table */ } } } diff --git a/Build/source/libs/lua53/lua53-src/src/lgc.h b/Build/source/libs/lua53/lua53-src/src/lgc.h index aed3e18a5f0..425cd7cef34 100644 --- a/Build/source/libs/lua53/lua53-src/src/lgc.h +++ b/Build/source/libs/lua53/lua53-src/src/lgc.h @@ -1,5 +1,5 @@ /* -** $Id: lgc.h,v 2.91 2015/12/21 13:02:14 roberto Exp $ +** $Id: lgc.h,v 2.91.1.1 2017/04/19 17:39:34 roberto Exp $ ** Garbage Collector ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/linit.c b/Build/source/libs/lua53/lua53-src/src/linit.c index afcaf98b24b..480da52c7e5 100644 --- a/Build/source/libs/lua53/lua53-src/src/linit.c +++ b/Build/source/libs/lua53/lua53-src/src/linit.c @@ -1,5 +1,5 @@ /* -** $Id: linit.c,v 1.39 2016/12/04 20:17:24 roberto Exp $ +** $Id: linit.c,v 1.39.1.1 2017/04/19 17:20:42 roberto Exp $ ** Initialization of libraries for lua.c and other clients ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/liolib.c b/Build/source/libs/lua53/lua53-src/src/liolib.c index d47be5a27df..76f372acbe8 100644 --- a/Build/source/libs/lua53/lua53-src/src/liolib.c +++ b/Build/source/libs/lua53/lua53-src/src/liolib.c @@ -1,5 +1,5 @@ /* -** $Id: liolib.c,v 2.151 2016/12/20 18:37:00 roberto Exp $ +** $Id: liolib.c,v 2.151.1.1 2017/04/19 17:29:57 roberto Exp $ ** Standard I/O (and system) library ** See Copyright Notice in lua.h */ @@ -209,11 +209,16 @@ static int aux_close (lua_State *L) { } +static int f_close (lua_State *L) { + tofile(L); /* make sure argument is an open stream */ + return aux_close(L); +} + + static int io_close (lua_State *L) { if (lua_isnone(L, 1)) /* no argument? */ lua_getfield(L, LUA_REGISTRYINDEX, IO_OUTPUT); /* use standard output */ - tofile(L); /* make sure argument is an open stream */ - return aux_close(L); + return f_close(L); } @@ -715,7 +720,7 @@ static const luaL_Reg iolib[] = { ** methods for file handles */ static const luaL_Reg flib[] = { - {"close", io_close}, + {"close", f_close}, {"flush", f_flush}, {"lines", f_lines}, {"read", f_read}, diff --git a/Build/source/libs/lua53/lua53-src/src/liolib.c.orig b/Build/source/libs/lua53/lua53-src/src/liolib.c.orig index 156840358d0..8a9e75cd089 100644 --- a/Build/source/libs/lua53/lua53-src/src/liolib.c.orig +++ b/Build/source/libs/lua53/lua53-src/src/liolib.c.orig @@ -1,5 +1,5 @@ /* -** $Id: liolib.c,v 2.151 2016/12/20 18:37:00 roberto Exp $ +** $Id: liolib.c,v 2.151.1.1 2017/04/19 17:29:57 roberto Exp $ ** Standard I/O (and system) library ** See Copyright Notice in lua.h */ @@ -206,11 +206,16 @@ static int aux_close (lua_State *L) { } +static int f_close (lua_State *L) { + tofile(L); /* make sure argument is an open stream */ + return aux_close(L); +} + + static int io_close (lua_State *L) { if (lua_isnone(L, 1)) /* no argument? */ lua_getfield(L, LUA_REGISTRYINDEX, IO_OUTPUT); /* use standard output */ - tofile(L); /* make sure argument is an open stream */ - return aux_close(L); + return f_close(L); } @@ -712,7 +717,7 @@ static const luaL_Reg iolib[] = { ** methods for file handles */ static const luaL_Reg flib[] = { - {"close", io_close}, + {"close", f_close}, {"flush", f_flush}, {"lines", f_lines}, {"read", f_read}, diff --git a/Build/source/libs/lua53/lua53-src/src/llex.c b/Build/source/libs/lua53/lua53-src/src/llex.c index 70328273f7a..66fd411ba9d 100644 --- a/Build/source/libs/lua53/lua53-src/src/llex.c +++ b/Build/source/libs/lua53/lua53-src/src/llex.c @@ -1,5 +1,5 @@ /* -** $Id: llex.c,v 2.96 2016/05/02 14:02:12 roberto Exp $ +** $Id: llex.c,v 2.96.1.1 2017/04/19 17:20:42 roberto Exp $ ** Lexical Analyzer ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/llex.h b/Build/source/libs/lua53/lua53-src/src/llex.h index 2363d87e40e..2ed0af66a48 100644 --- a/Build/source/libs/lua53/lua53-src/src/llex.h +++ b/Build/source/libs/lua53/lua53-src/src/llex.h @@ -1,5 +1,5 @@ /* -** $Id: llex.h,v 1.79 2016/05/02 14:02:12 roberto Exp $ +** $Id: llex.h,v 1.79.1.1 2017/04/19 17:20:42 roberto Exp $ ** Lexical Analyzer ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/llimits.h b/Build/source/libs/lua53/lua53-src/src/llimits.h index f21377fef98..d1036f6bc8d 100644 --- a/Build/source/libs/lua53/lua53-src/src/llimits.h +++ b/Build/source/libs/lua53/lua53-src/src/llimits.h @@ -1,5 +1,5 @@ /* -** $Id: llimits.h,v 1.141 2015/11/19 19:16:22 roberto Exp $ +** $Id: llimits.h,v 1.141.1.1 2017/04/19 17:20:42 roberto Exp $ ** Limits, basic types, and some other 'installation-dependent' definitions ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lmathlib.c b/Build/source/libs/lua53/lua53-src/src/lmathlib.c index b7f8baee076..7ef7e593fd3 100644 --- a/Build/source/libs/lua53/lua53-src/src/lmathlib.c +++ b/Build/source/libs/lua53/lua53-src/src/lmathlib.c @@ -1,5 +1,5 @@ /* -** $Id: lmathlib.c,v 1.119 2016/12/22 13:08:50 roberto Exp $ +** $Id: lmathlib.c,v 1.119.1.1 2017/04/19 17:20:42 roberto Exp $ ** Standard mathematical library ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lmem.c b/Build/source/libs/lua53/lua53-src/src/lmem.c index 0a0476cc773..0241cc3bac0 100644 --- a/Build/source/libs/lua53/lua53-src/src/lmem.c +++ b/Build/source/libs/lua53/lua53-src/src/lmem.c @@ -1,5 +1,5 @@ /* -** $Id: lmem.c,v 1.91 2015/03/06 19:45:54 roberto Exp $ +** $Id: lmem.c,v 1.91.1.1 2017/04/19 17:20:42 roberto Exp $ ** Interface to Memory Manager ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lmem.h b/Build/source/libs/lua53/lua53-src/src/lmem.h index 30f484895e7..357b1e43e7f 100644 --- a/Build/source/libs/lua53/lua53-src/src/lmem.h +++ b/Build/source/libs/lua53/lua53-src/src/lmem.h @@ -1,5 +1,5 @@ /* -** $Id: lmem.h,v 1.43 2014/12/19 17:26:14 roberto Exp $ +** $Id: lmem.h,v 1.43.1.1 2017/04/19 17:20:42 roberto Exp $ ** Interface to Memory Manager ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/loadlib.c b/Build/source/libs/lua53/lua53-src/src/loadlib.c index 4791e748b16..45f44d3225a 100644 --- a/Build/source/libs/lua53/lua53-src/src/loadlib.c +++ b/Build/source/libs/lua53/lua53-src/src/loadlib.c @@ -1,5 +1,5 @@ /* -** $Id: loadlib.c,v 1.130 2017/01/12 17:14:26 roberto Exp $ +** $Id: loadlib.c,v 1.130.1.1 2017/04/19 17:20:42 roberto Exp $ ** Dynamic library loader for Lua ** See Copyright Notice in lua.h ** diff --git a/Build/source/libs/lua53/lua53-src/src/lobject.c b/Build/source/libs/lua53/lua53-src/src/lobject.c index 2da76899a27..2218c8cdd77 100644 --- a/Build/source/libs/lua53/lua53-src/src/lobject.c +++ b/Build/source/libs/lua53/lua53-src/src/lobject.c @@ -1,5 +1,5 @@ /* -** $Id: lobject.c,v 2.113 2016/12/22 13:08:50 roberto Exp $ +** $Id: lobject.c,v 2.113.1.1 2017/04/19 17:29:57 roberto Exp $ ** Some generic functions over Lua objects ** See Copyright Notice in lua.h */ @@ -435,7 +435,8 @@ const char *luaO_pushvfstring (lua_State *L, const char *fmt, va_list argp) { } case 'p': { /* a pointer */ char buff[4*sizeof(void *) + 8]; /* should be enough space for a '%p' */ - int l = l_sprintf(buff, sizeof(buff), "%p", va_arg(argp, void *)); + void *p = va_arg(argp, void *); + int l = lua_pointer2str(buff, sizeof(buff), p); pushstr(L, buff, l); break; } diff --git a/Build/source/libs/lua53/lua53-src/src/lobject.h b/Build/source/libs/lua53/lua53-src/src/lobject.h index 3c042289492..24088614027 100644 --- a/Build/source/libs/lua53/lua53-src/src/lobject.h +++ b/Build/source/libs/lua53/lua53-src/src/lobject.h @@ -1,5 +1,5 @@ /* -** $Id: lobject.h,v 2.117 2016/08/01 19:51:24 roberto Exp $ +** $Id: lobject.h,v 2.117.1.1 2017/04/19 17:39:34 roberto Exp $ ** Type definitions for Lua objects ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lopcodes.c b/Build/source/libs/lua53/lua53-src/src/lopcodes.c index a1cbef85737..5ca3eb261a4 100644 --- a/Build/source/libs/lua53/lua53-src/src/lopcodes.c +++ b/Build/source/libs/lua53/lua53-src/src/lopcodes.c @@ -1,5 +1,5 @@ /* -** $Id: lopcodes.c,v 1.55 2015/01/05 13:48:33 roberto Exp $ +** $Id: lopcodes.c,v 1.55.1.1 2017/04/19 17:20:42 roberto Exp $ ** Opcodes for Lua virtual machine ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lopcodes.h b/Build/source/libs/lua53/lua53-src/src/lopcodes.h index f9b438e15d9..df6c2264b7b 100644 --- a/Build/source/libs/lua53/lua53-src/src/lopcodes.h +++ b/Build/source/libs/lua53/lua53-src/src/lopcodes.h @@ -1,5 +1,5 @@ /* -** $Id: lopcodes.h,v 1.149 2016/07/19 17:12:21 roberto Exp $ +** $Id: lopcodes.h,v 1.149.1.1 2017/04/19 17:20:42 roberto Exp $ ** Opcodes for Lua virtual machine ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lopcodes.h.orig b/Build/source/libs/lua53/lua53-src/src/lopcodes.h.orig index bbc4b61968a..6feaa1cd07a 100644 --- a/Build/source/libs/lua53/lua53-src/src/lopcodes.h.orig +++ b/Build/source/libs/lua53/lua53-src/src/lopcodes.h.orig @@ -1,5 +1,5 @@ /* -** $Id: lopcodes.h,v 1.149 2016/07/19 17:12:21 roberto Exp $ +** $Id: lopcodes.h,v 1.149.1.1 2017/04/19 17:20:42 roberto Exp $ ** Opcodes for Lua virtual machine ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/loslib.c b/Build/source/libs/lua53/lua53-src/src/loslib.c index 5a94eb9068d..de590c6b717 100644 --- a/Build/source/libs/lua53/lua53-src/src/loslib.c +++ b/Build/source/libs/lua53/lua53-src/src/loslib.c @@ -1,5 +1,5 @@ /* -** $Id: loslib.c,v 1.65 2016/07/18 17:58:58 roberto Exp $ +** $Id: loslib.c,v 1.65.1.1 2017/04/19 17:29:57 roberto Exp $ ** Standard Operating System library ** See Copyright Notice in lua.h */ @@ -293,7 +293,8 @@ static int os_date (lua_State *L) { else stm = l_localtime(&t, &tmr); if (stm == NULL) /* invalid date? */ - luaL_error(L, "time result cannot be represented in this installation"); + return luaL_error(L, + "time result cannot be represented in this installation"); if (strcmp(s, "*t") == 0) { lua_createtable(L, 0, 9); /* 9 = number of fields */ setallfields(L, stm); @@ -340,7 +341,8 @@ static int os_time (lua_State *L) { setallfields(L, &ts); /* update fields with normalized values */ } if (t != (time_t)(l_timet)t || t == (time_t)(-1)) - luaL_error(L, "time result cannot be represented in this installation"); + return luaL_error(L, + "time result cannot be represented in this installation"); l_pushtime(L, t); return 1; } diff --git a/Build/source/libs/lua53/lua53-src/src/lparser.c b/Build/source/libs/lua53/lua53-src/src/lparser.c index cd4512d4d41..cc54de43c63 100644 --- a/Build/source/libs/lua53/lua53-src/src/lparser.c +++ b/Build/source/libs/lua53/lua53-src/src/lparser.c @@ -1,5 +1,5 @@ /* -** $Id: lparser.c,v 2.155 2016/08/01 19:51:24 roberto Exp $ +** $Id: lparser.c,v 2.155.1.2 2017/04/29 18:11:40 roberto Exp $ ** Lua Parser ** See Copyright Notice in lua.h */ @@ -1392,7 +1392,7 @@ static void test_then_block (LexState *ls, int *escapelist) { luaK_goiffalse(ls->fs, &v); /* will jump to label if condition is true */ enterblock(fs, &bl, 0); /* must enter block before 'goto' */ gotostat(ls, v.t); /* handle goto/break */ - skipnoopstat(ls); /* skip other no-op statements */ + while (testnext(ls, ';')) {} /* skip colons */ if (block_follow(ls, 0)) { /* 'goto' is the entire block? */ leaveblock(fs); return; /* and that is it */ diff --git a/Build/source/libs/lua53/lua53-src/src/lparser.h b/Build/source/libs/lua53/lua53-src/src/lparser.h index 02e9b03aebc..f45b23cba56 100644 --- a/Build/source/libs/lua53/lua53-src/src/lparser.h +++ b/Build/source/libs/lua53/lua53-src/src/lparser.h @@ -1,5 +1,5 @@ /* -** $Id: lparser.h,v 1.76 2015/12/30 18:16:13 roberto Exp $ +** $Id: lparser.h,v 1.76.1.1 2017/04/19 17:20:42 roberto Exp $ ** Lua Parser ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lprefix.h b/Build/source/libs/lua53/lua53-src/src/lprefix.h index 02daa837f55..9a749a3f30c 100644 --- a/Build/source/libs/lua53/lua53-src/src/lprefix.h +++ b/Build/source/libs/lua53/lua53-src/src/lprefix.h @@ -1,5 +1,5 @@ /* -** $Id: lprefix.h,v 1.2 2014/12/29 16:54:13 roberto Exp $ +** $Id: lprefix.h,v 1.2.1.1 2017/04/19 17:20:42 roberto Exp $ ** Definitions for Lua code that must come before any other header file ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lstate.c b/Build/source/libs/lua53/lua53-src/src/lstate.c index 9194ac3419e..c1a76643c33 100644 --- a/Build/source/libs/lua53/lua53-src/src/lstate.c +++ b/Build/source/libs/lua53/lua53-src/src/lstate.c @@ -1,5 +1,5 @@ /* -** $Id: lstate.c,v 2.133 2015/11/13 12:16:51 roberto Exp $ +** $Id: lstate.c,v 2.133.1.1 2017/04/19 17:39:34 roberto Exp $ ** Global State ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lstate.h b/Build/source/libs/lua53/lua53-src/src/lstate.h index a469466c447..56b37410000 100644 --- a/Build/source/libs/lua53/lua53-src/src/lstate.h +++ b/Build/source/libs/lua53/lua53-src/src/lstate.h @@ -1,5 +1,5 @@ /* -** $Id: lstate.h,v 2.133 2016/12/22 13:08:50 roberto Exp $ +** $Id: lstate.h,v 2.133.1.1 2017/04/19 17:39:34 roberto Exp $ ** Global State ** See Copyright Notice in lua.h */ @@ -26,6 +26,24 @@ ** 'tobefnz': all objects ready to be finalized; ** 'fixedgc': all objects that are not to be collected (currently ** only small strings, such as reserved words). +** +** Moreover, there is another set of lists that control gray objects. +** These lists are linked by fields 'gclist'. (All objects that +** can become gray have such a field. The field is not the same +** in all objects, but it always has this name.) Any gray object +** must belong to one of these lists, and all objects in these lists +** must be gray: +** +** 'gray': regular gray objects, still waiting to be visited. +** 'grayagain': objects that must be revisited at the atomic phase. +** That includes +** - black objects got in a write barrier; +** - all kinds of weak tables during propagation phase; +** - all threads. +** 'weak': tables with weak values to be cleared; +** 'ephemeron': ephemeron tables with white->white entries; +** 'allweak': tables with weak keys and/or weak values to be cleared. +** The last three lists are used only during the atomic phase. */ diff --git a/Build/source/libs/lua53/lua53-src/src/lstring.c b/Build/source/libs/lua53/lua53-src/src/lstring.c index 9351766fd63..6257f211d9e 100644 --- a/Build/source/libs/lua53/lua53-src/src/lstring.c +++ b/Build/source/libs/lua53/lua53-src/src/lstring.c @@ -1,5 +1,5 @@ /* -** $Id: lstring.c,v 2.56 2015/11/23 11:32:51 roberto Exp $ +** $Id: lstring.c,v 2.56.1.1 2017/04/19 17:20:42 roberto Exp $ ** String table (keeps all strings handled by Lua) ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lstring.h b/Build/source/libs/lua53/lua53-src/src/lstring.h index 27efd207726..d612abd3332 100644 --- a/Build/source/libs/lua53/lua53-src/src/lstring.h +++ b/Build/source/libs/lua53/lua53-src/src/lstring.h @@ -1,5 +1,5 @@ /* -** $Id: lstring.h,v 1.61 2015/11/03 15:36:01 roberto Exp $ +** $Id: lstring.h,v 1.61.1.1 2017/04/19 17:20:42 roberto Exp $ ** String table (keep all strings handled by Lua) ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lstrlib.c b/Build/source/libs/lua53/lua53-src/src/lstrlib.c index c7aa755fabd..b4bed7e93d1 100644 --- a/Build/source/libs/lua53/lua53-src/src/lstrlib.c +++ b/Build/source/libs/lua53/lua53-src/src/lstrlib.c @@ -1,5 +1,5 @@ /* -** $Id: lstrlib.c,v 1.254 2016/12/22 13:08:50 roberto Exp $ +** $Id: lstrlib.c,v 1.254.1.1 2017/04/19 17:29:57 roberto Exp $ ** Standard library for string operations and pattern-matching ** See Copyright Notice in lua.h */ @@ -879,7 +879,7 @@ static int lua_number2strx (lua_State *L, char *buff, int sz, buff[i] = toupper(uchar(buff[i])); } else if (fmt[SIZELENMOD] != 'a') - luaL_error(L, "modifiers for format '%%a'/'%%A' not implemented"); + return luaL_error(L, "modifiers for format '%%a'/'%%A' not implemented"); return n; } @@ -1199,8 +1199,8 @@ static int getnum (const char **fmt, int df) { static int getnumlimit (Header *h, const char **fmt, int df) { int sz = getnum(fmt, df); if (sz > MAXINTSIZE || sz <= 0) - luaL_error(h->L, "integral size (%d) out of limits [1,%d]", - sz, MAXINTSIZE); + return luaL_error(h->L, "integral size (%d) out of limits [1,%d]", + sz, MAXINTSIZE); return sz; } diff --git a/Build/source/libs/lua53/lua53-src/src/ltable.c b/Build/source/libs/lua53/lua53-src/src/ltable.c index d080189f28d..ea4fe7fcb31 100644 --- a/Build/source/libs/lua53/lua53-src/src/ltable.c +++ b/Build/source/libs/lua53/lua53-src/src/ltable.c @@ -1,5 +1,5 @@ /* -** $Id: ltable.c,v 2.118 2016/11/07 12:38:35 roberto Exp $ +** $Id: ltable.c,v 2.118.1.4 2018/06/08 16:22:51 roberto Exp $ ** Lua tables (hash) ** See Copyright Notice in lua.h */ @@ -223,7 +223,9 @@ static unsigned int computesizes (unsigned int nums[], unsigned int *pna) { unsigned int na = 0; /* number of elements to go to array part */ unsigned int optimal = 0; /* optimal size for array part */ /* loop while keys can fill more than half of total size */ - for (i = 0, twotoi = 1; *pna > twotoi / 2; i++, twotoi *= 2) { + for (i = 0, twotoi = 1; + twotoi > 0 && *pna > twotoi / 2; + i++, twotoi *= 2) { if (nums[i] > 0) { a += nums[i]; if (a > twotoi/2) { /* more than half elements present? */ @@ -330,17 +332,34 @@ static void setnodevector (lua_State *L, Table *t, unsigned int size) { } +typedef struct { + Table *t; + unsigned int nhsize; +} AuxsetnodeT; + + +static void auxsetnode (lua_State *L, void *ud) { + AuxsetnodeT *asn = cast(AuxsetnodeT *, ud); + setnodevector(L, asn->t, asn->nhsize); +} + + void luaH_resize (lua_State *L, Table *t, unsigned int nasize, unsigned int nhsize) { unsigned int i; int j; + AuxsetnodeT asn; unsigned int oldasize = t->sizearray; int oldhsize = allocsizenode(t); Node *nold = t->node; /* save old hash ... */ if (nasize > oldasize) /* array part must grow? */ setarrayvector(L, t, nasize); /* create new hash part with appropriate size */ - setnodevector(L, t, nhsize); + asn.t = t; asn.nhsize = nhsize; + if (luaD_rawrunprotected(L, auxsetnode, &asn) != LUA_OK) { /* mem. error? */ + setarrayvector(L, t, oldasize); /* array back to its original size */ + luaD_throw(L, LUA_ERRMEM); /* rethrow memory error */ + } if (nasize < oldasize) { /* array part must shrink? */ t->sizearray = nasize; /* re-insert elements from vanishing slice */ @@ -610,13 +629,13 @@ void luaH_setint (lua_State *L, Table *t, lua_Integer key, TValue *value) { } -static int unbound_search (Table *t, unsigned int j) { - unsigned int i = j; /* i is zero or a present index */ +static lua_Unsigned unbound_search (Table *t, lua_Unsigned j) { + lua_Unsigned i = j; /* i is zero or a present index */ j++; /* find 'i' and 'j' such that i is present and j is not */ while (!ttisnil(luaH_getint(t, j))) { i = j; - if (j > cast(unsigned int, MAX_INT)/2) { /* overflow? */ + if (j > l_castS2U(LUA_MAXINTEGER) / 2) { /* overflow? */ /* table was built with bad purposes: resort to linear search */ i = 1; while (!ttisnil(luaH_getint(t, i))) i++; @@ -626,7 +645,7 @@ static int unbound_search (Table *t, unsigned int j) { } /* now do a binary search between them */ while (j - i > 1) { - unsigned int m = (i+j)/2; + lua_Unsigned m = (i+j)/2; if (ttisnil(luaH_getint(t, m))) j = m; else i = m; } @@ -638,7 +657,7 @@ static int unbound_search (Table *t, unsigned int j) { ** Try to find a boundary in table 't'. A 'boundary' is an integer index ** such that t[i] is non-nil and t[i+1] is nil (and 0 if t[1] is nil). */ -int luaH_getn (Table *t) { +lua_Unsigned luaH_getn (Table *t) { unsigned int j = t->sizearray; if (j > 0 && ttisnil(&t->array[j - 1])) { /* there is a boundary in the array part: (binary) search for it */ diff --git a/Build/source/libs/lua53/lua53-src/src/ltable.h b/Build/source/libs/lua53/lua53-src/src/ltable.h index 6da9024fe1f..92db0ac7bf1 100644 --- a/Build/source/libs/lua53/lua53-src/src/ltable.h +++ b/Build/source/libs/lua53/lua53-src/src/ltable.h @@ -1,5 +1,5 @@ /* -** $Id: ltable.h,v 2.23 2016/12/22 13:08:50 roberto Exp $ +** $Id: ltable.h,v 2.23.1.2 2018/05/24 19:39:05 roberto Exp $ ** Lua tables (hash) ** See Copyright Notice in lua.h */ @@ -54,7 +54,7 @@ LUAI_FUNC void luaH_resize (lua_State *L, Table *t, unsigned int nasize, LUAI_FUNC void luaH_resizearray (lua_State *L, Table *t, unsigned int nasize); LUAI_FUNC void luaH_free (lua_State *L, Table *t); LUAI_FUNC int luaH_next (lua_State *L, Table *t, StkId key); -LUAI_FUNC int luaH_getn (Table *t); +LUAI_FUNC lua_Unsigned luaH_getn (Table *t); #if defined(LUA_DEBUG) diff --git a/Build/source/libs/lua53/lua53-src/src/ltablib.c b/Build/source/libs/lua53/lua53-src/src/ltablib.c index 98b2f871379..c5349578ec7 100644 --- a/Build/source/libs/lua53/lua53-src/src/ltablib.c +++ b/Build/source/libs/lua53/lua53-src/src/ltablib.c @@ -1,5 +1,5 @@ /* -** $Id: ltablib.c,v 1.93 2016/02/25 19:41:54 roberto Exp $ +** $Id: ltablib.c,v 1.93.1.1 2017/04/19 17:20:42 roberto Exp $ ** Library for Table Manipulation ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/ltm.c b/Build/source/libs/lua53/lua53-src/src/ltm.c index 14e52578884..0e7c713214c 100644 --- a/Build/source/libs/lua53/lua53-src/src/ltm.c +++ b/Build/source/libs/lua53/lua53-src/src/ltm.c @@ -1,5 +1,5 @@ /* -** $Id: ltm.c,v 2.38 2016/12/22 13:08:50 roberto Exp $ +** $Id: ltm.c,v 2.38.1.1 2017/04/19 17:39:34 roberto Exp $ ** Tag methods ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/ltm.h b/Build/source/libs/lua53/lua53-src/src/ltm.h index 63db7269bbf..8170688daeb 100644 --- a/Build/source/libs/lua53/lua53-src/src/ltm.h +++ b/Build/source/libs/lua53/lua53-src/src/ltm.h @@ -1,5 +1,5 @@ /* -** $Id: ltm.h,v 2.22 2016/02/26 19:20:15 roberto Exp $ +** $Id: ltm.h,v 2.22.1.1 2017/04/19 17:20:42 roberto Exp $ ** Tag methods ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lua.c b/Build/source/libs/lua53/lua53-src/src/lua.c index 3f082da6be6..ca5b298523b 100644 --- a/Build/source/libs/lua53/lua53-src/src/lua.c +++ b/Build/source/libs/lua53/lua53-src/src/lua.c @@ -1,5 +1,5 @@ /* -** $Id: lua.c,v 1.230 2017/01/12 17:14:26 roberto Exp $ +** $Id: lua.c,v 1.230.1.1 2017/04/19 17:29:57 roberto Exp $ ** Lua stand-alone interpreter ** See Copyright Notice in lua.h */ @@ -138,7 +138,7 @@ static void print_usage (const char *badoption) { "Available options are:\n" " -e stat execute string 'stat'\n" " -i enter interactive mode after executing 'script'\n" - " -l name require library 'name'\n" + " -l name require library 'name' into global 'name'\n" " -v show version information\n" " -E ignore environment variables\n" " -- stop handling options\n" diff --git a/Build/source/libs/lua53/lua53-src/src/lua.h b/Build/source/libs/lua53/lua53-src/src/lua.h index 26c0e2d698c..c236e360957 100644 --- a/Build/source/libs/lua53/lua53-src/src/lua.h +++ b/Build/source/libs/lua53/lua53-src/src/lua.h @@ -1,5 +1,5 @@ /* -** $Id: lua.h,v 1.332 2016/12/22 15:51:20 roberto Exp $ +** $Id: lua.h,v 1.332.1.2 2018/06/13 16:58:17 roberto Exp $ ** Lua - A Scripting Language ** Lua.org, PUC-Rio, Brazil (http://www.lua.org) ** See Copyright Notice at the end of this file @@ -19,11 +19,11 @@ #define LUA_VERSION_MAJOR "5" #define LUA_VERSION_MINOR "3" #define LUA_VERSION_NUM 503 -#define LUA_VERSION_RELEASE "4" +#define LUA_VERSION_RELEASE "5" #define LUA_VERSION "Lua " LUA_VERSION_MAJOR "." LUA_VERSION_MINOR #define LUA_RELEASE LUA_VERSION "." LUA_VERSION_RELEASE -#define LUA_COPYRIGHT LUA_RELEASE " Copyright (C) 1994-2017 Lua.org, PUC-Rio" +#define LUA_COPYRIGHT LUA_RELEASE " Copyright (C) 1994-2018 Lua.org, PUC-Rio" #define LUA_AUTHORS "R. Ierusalimschy, L. H. de Figueiredo, W. Celes" @@ -460,7 +460,7 @@ struct lua_Debug { /****************************************************************************** -* Copyright (C) 1994-2017 Lua.org, PUC-Rio. +* Copyright (C) 1994-2018 Lua.org, PUC-Rio. * * Permission is hereby granted, free of charge, to any person obtaining * a copy of this software and associated documentation files (the diff --git a/Build/source/libs/lua53/lua53-src/src/luac.c b/Build/source/libs/lua53/lua53-src/src/luac.c index c0c91d017ae..549ad395004 100644 --- a/Build/source/libs/lua53/lua53-src/src/luac.c +++ b/Build/source/libs/lua53/lua53-src/src/luac.c @@ -1,5 +1,5 @@ /* -** $Id: luac.c,v 1.75 2015/03/12 01:58:27 lhf Exp $ +** $Id: luac.c,v 1.76 2018/06/19 01:32:02 lhf Exp $ ** Lua compiler (saves bytecodes to files; also lists bytecodes) ** See Copyright Notice in lua.h */ @@ -206,7 +206,7 @@ int main(int argc, char* argv[]) } /* -** $Id: luac.c,v 1.75 2015/03/12 01:58:27 lhf Exp $ +** $Id: luac.c,v 1.76 2018/06/19 01:32:02 lhf Exp $ ** print bytecodes ** See Copyright Notice in lua.h */ @@ -348,6 +348,7 @@ static void PrintCode(const Proto* f) case OP_ADD: case OP_SUB: case OP_MUL: + case OP_MOD: case OP_POW: case OP_DIV: case OP_IDIV: diff --git a/Build/source/libs/lua53/lua53-src/src/luaconf.h b/Build/source/libs/lua53/lua53-src/src/luaconf.h index dbd399e3ca7..9eeeea69e20 100644 --- a/Build/source/libs/lua53/lua53-src/src/luaconf.h +++ b/Build/source/libs/lua53/lua53-src/src/luaconf.h @@ -1,5 +1,5 @@ /* -** $Id: luaconf.h,v 1.259 2016/12/22 13:08:50 roberto Exp $ +** $Id: luaconf.h,v 1.259.1.1 2017/04/19 17:29:57 roberto Exp $ ** Configuration file for Lua ** See Copyright Notice in lua.h */ @@ -604,8 +604,6 @@ */ #if !defined(LUA_USE_C89) #define l_sprintf(s,sz,f,i) snprintf(s,sz,f,i) -/* Should we use this line ? */ -/*#define l_sprintf(s,sz,f,i) ((void)(sz), sprintf(s,f,i))*/ #else #define l_sprintf(s,sz,f,i) ((void)(sz), sprintf(s,f,i)) #endif @@ -622,6 +620,13 @@ #endif +/* +@@ lua_pointer2str converts a pointer to a readable string in a +** non-specified way. +*/ +#define lua_pointer2str(buff,sz,p) l_sprintf(buff,sz,"%p",p) + + /* @@ lua_number2strx converts a float to an hexadecimal numeric string. ** In C99, 'sprintf' (with format specifiers '%a'/'%A') does that. diff --git a/Build/source/libs/lua53/lua53-src/src/lualib.h b/Build/source/libs/lua53/lua53-src/src/lualib.h index 6c0bc4cb084..f5304aa0dd0 100644 --- a/Build/source/libs/lua53/lua53-src/src/lualib.h +++ b/Build/source/libs/lua53/lua53-src/src/lualib.h @@ -1,5 +1,5 @@ /* -** $Id: lualib.h,v 1.45 2017/01/12 17:14:26 roberto Exp $ +** $Id: lualib.h,v 1.45.1.1 2017/04/19 17:20:42 roberto Exp $ ** Lua standard libraries ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lundump.c b/Build/source/libs/lua53/lua53-src/src/lundump.c index 4080af9c0d9..7a67d75aaa0 100644 --- a/Build/source/libs/lua53/lua53-src/src/lundump.c +++ b/Build/source/libs/lua53/lua53-src/src/lundump.c @@ -1,5 +1,5 @@ /* -** $Id: lundump.c,v 2.44 2015/11/02 16:09:30 roberto Exp $ +** $Id: lundump.c,v 2.44.1.1 2017/04/19 17:20:42 roberto Exp $ ** load precompiled Lua chunks ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lundump.h b/Build/source/libs/lua53/lua53-src/src/lundump.h index fe4a97463f8..f3e2e9061d6 100644 --- a/Build/source/libs/lua53/lua53-src/src/lundump.h +++ b/Build/source/libs/lua53/lua53-src/src/lundump.h @@ -1,5 +1,5 @@ /* -** $Id: lundump.h,v 1.45 2015/09/08 15:41:05 roberto Exp $ +** $Id: lundump.h,v 1.45.1.1 2017/04/19 17:20:42 roberto Exp $ ** load precompiled Lua chunks ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lundump.h.orig b/Build/source/libs/lua53/lua53-src/src/lundump.h.orig index aa5cc82f1b5..ce492d689cd 100644 --- a/Build/source/libs/lua53/lua53-src/src/lundump.h.orig +++ b/Build/source/libs/lua53/lua53-src/src/lundump.h.orig @@ -1,5 +1,5 @@ /* -** $Id: lundump.h,v 1.45 2015/09/08 15:41:05 roberto Exp $ +** $Id: lundump.h,v 1.45.1.1 2017/04/19 17:20:42 roberto Exp $ ** load precompiled Lua chunks ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lutf8lib.c b/Build/source/libs/lua53/lua53-src/src/lutf8lib.c index de9e3dcdd64..10bd238a71d 100644 --- a/Build/source/libs/lua53/lua53-src/src/lutf8lib.c +++ b/Build/source/libs/lua53/lua53-src/src/lutf8lib.c @@ -1,5 +1,5 @@ /* -** $Id: lutf8lib.c,v 1.16 2016/12/22 13:08:50 roberto Exp $ +** $Id: lutf8lib.c,v 1.16.1.1 2017/04/19 17:29:57 roberto Exp $ ** Standard library for UTF-8 manipulation ** See Copyright Notice in lua.h */ @@ -171,7 +171,7 @@ static int byteoffset (lua_State *L) { } else { if (iscont(s + posi)) - luaL_error(L, "initial position is a continuation byte"); + return luaL_error(L, "initial position is a continuation byte"); if (n < 0) { while (n < 0 && posi > 0) { /* move back */ do { /* find beginning of previous character */ diff --git a/Build/source/libs/lua53/lua53-src/src/lvm.c b/Build/source/libs/lua53/lua53-src/src/lvm.c index 84ade6b2fa6..cc43d8714db 100644 --- a/Build/source/libs/lua53/lua53-src/src/lvm.c +++ b/Build/source/libs/lua53/lua53-src/src/lvm.c @@ -1,5 +1,5 @@ /* -** $Id: lvm.c,v 2.268 2016/02/05 19:59:14 roberto Exp $ +** $Id: lvm.c,v 2.268.1.1 2017/04/19 17:39:34 roberto Exp $ ** Lua virtual machine ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lvm.h b/Build/source/libs/lua53/lua53-src/src/lvm.h index 422f8719491..a8f954f04ce 100644 --- a/Build/source/libs/lua53/lua53-src/src/lvm.h +++ b/Build/source/libs/lua53/lua53-src/src/lvm.h @@ -1,5 +1,5 @@ /* -** $Id: lvm.h,v 2.41 2016/12/22 13:08:50 roberto Exp $ +** $Id: lvm.h,v 2.41.1.1 2017/04/19 17:20:42 roberto Exp $ ** Lua virtual machine ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lzio.c b/Build/source/libs/lua53/lua53-src/src/lzio.c index c9e1f491f34..6f79094410f 100644 --- a/Build/source/libs/lua53/lua53-src/src/lzio.c +++ b/Build/source/libs/lua53/lua53-src/src/lzio.c @@ -1,5 +1,5 @@ /* -** $Id: lzio.c,v 1.37 2015/09/08 15:41:05 roberto Exp $ +** $Id: lzio.c,v 1.37.1.1 2017/04/19 17:20:42 roberto Exp $ ** Buffered streams ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/lua53/lua53-src/src/lzio.h b/Build/source/libs/lua53/lua53-src/src/lzio.h index e7b6f34b1e3..d8978708157 100644 --- a/Build/source/libs/lua53/lua53-src/src/lzio.h +++ b/Build/source/libs/lua53/lua53-src/src/lzio.h @@ -1,5 +1,5 @@ /* -** $Id: lzio.h,v 1.31 2015/09/08 15:41:05 roberto Exp $ +** $Id: lzio.h,v 1.31.1.1 2017/04/19 17:20:42 roberto Exp $ ** Buffered streams ** See Copyright Notice in lua.h */ diff --git a/Build/source/libs/luajit/native/Makefile.am b/Build/source/libs/luajit/native/Makefile.am index f89c2fa7629..c9ed9d7a114 100644 --- a/Build/source/libs/luajit/native/Makefile.am +++ b/Build/source/libs/luajit/native/Makefile.am @@ -28,6 +28,7 @@ buildvm_arch.h: minilua$(EXEEXT) $(LUAJIT_TREE)/dynasm/dynasm.lua `cat ../dynasm_flags` \ -o $@ $(srcdir)/$(LUAJIT_TREE)/src/vm_$(DASM_ARCH).dasc +minilua_CPPFLAGS = $(AM_CPPFLAGS) $(LUAJIT_DEFINES) `cat ../native_flags` nodist_minilua_SOURCES = \ @LUAJIT_TREE@/src/host/minilua.c minilua_LDADD = $(MATH_LIB) diff --git a/Build/source/libs/zziplib/zziplib-src/zzip/lib.h b/Build/source/libs/zziplib/zziplib-src/zzip/lib.h index 4a02f5473e4..b09a1302829 100644 --- a/Build/source/libs/zziplib/zziplib-src/zzip/lib.h +++ b/Build/source/libs/zziplib/zziplib-src/zzip/lib.h @@ -16,6 +16,7 @@ #include #include #include +#include #ifdef __cplusplus extern "C" { -- cgit v1.2.3