Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/external/mit/lua/dist lua: merged 5.3.2



details:   https://anonhg.NetBSD.org/src/rev/06e11b09a7de
branches:  trunk
changeset: 343293:06e11b09a7de
user:      lneto <lneto%NetBSD.org@localhost>
date:      Thu Jan 28 14:41:39 2016 +0000

description:
lua: merged 5.3.2

diffstat:

 external/mit/lua/dist/Makefile        |    2 +-
 external/mit/lua/dist/README          |    2 +-
 external/mit/lua/dist/doc/lua.1       |    2 +-
 external/mit/lua/dist/doc/lua.css     |   26 ++
 external/mit/lua/dist/doc/luac.1      |    6 +-
 external/mit/lua/dist/doc/manual.html |  156 ++++++++-----
 external/mit/lua/dist/src/lapi.c      |  155 ++++++++-----
 external/mit/lua/dist/src/lapi.h      |    2 +-
 external/mit/lua/dist/src/lauxlib.c   |  104 ++++++--
 external/mit/lua/dist/src/lauxlib.h   |   20 +-
 external/mit/lua/dist/src/lbaselib.c  |   53 +---
 external/mit/lua/dist/src/lbitlib.c   |   53 ++--
 external/mit/lua/dist/src/lcode.c     |   40 +-
 external/mit/lua/dist/src/lcode.h     |    4 +-
 external/mit/lua/dist/src/lcorolib.c  |    4 +-
 external/mit/lua/dist/src/lctype.c    |    4 +-
 external/mit/lua/dist/src/lctype.h    |    4 +-
 external/mit/lua/dist/src/ldblib.c    |   14 +-
 external/mit/lua/dist/src/ldebug.c    |   14 +-
 external/mit/lua/dist/src/ldebug.h    |    2 +-
 external/mit/lua/dist/src/ldo.c       |  198 ++++++++++++-----
 external/mit/lua/dist/src/ldo.h       |   28 +-
 external/mit/lua/dist/src/ldump.c     |   10 +-
 external/mit/lua/dist/src/lfunc.c     |    4 +-
 external/mit/lua/dist/src/lfunc.h     |    2 +-
 external/mit/lua/dist/src/lgc.c       |   32 +-
 external/mit/lua/dist/src/lgc.h       |   43 ++-
 external/mit/lua/dist/src/linit.c     |   10 +-
 external/mit/lua/dist/src/liolib.c    |   33 ++-
 external/mit/lua/dist/src/llex.c      |   25 +-
 external/mit/lua/dist/src/llex.h      |    4 +-
 external/mit/lua/dist/src/llimits.h   |   44 ++-
 external/mit/lua/dist/src/lmathlib.c  |    8 +-
 external/mit/lua/dist/src/lmem.c      |    4 +-
 external/mit/lua/dist/src/lmem.h      |    4 +-
 external/mit/lua/dist/src/loadlib.c   |    6 +-
 external/mit/lua/dist/src/lobject.c   |   50 ++--
 external/mit/lua/dist/src/lobject.h   |  100 ++++----
 external/mit/lua/dist/src/lopcodes.c  |    8 +-
 external/mit/lua/dist/src/lopcodes.h  |    4 +-
 external/mit/lua/dist/src/loslib.c    |   74 ++++--
 external/mit/lua/dist/src/lparser.c   |   25 +-
 external/mit/lua/dist/src/lparser.h   |    6 +-
 external/mit/lua/dist/src/lprefix.h   |    4 +-
 external/mit/lua/dist/src/lstate.c    |   33 +-
 external/mit/lua/dist/src/lstate.h    |   16 +-
 external/mit/lua/dist/src/lstring.c   |   80 ++++--
 external/mit/lua/dist/src/lstring.h   |    6 +-
 external/mit/lua/dist/src/lstrlib.c   |  207 ++++++++++-------
 external/mit/lua/dist/src/ltable.c    |   94 ++++---
 external/mit/lua/dist/src/ltable.h    |    9 +-
 external/mit/lua/dist/src/ltablib.c   |  376 +++++++++++++++++++++------------
 external/mit/lua/dist/src/ltm.c       |   27 +-
 external/mit/lua/dist/src/ltm.h       |    4 +-
 external/mit/lua/dist/src/lua.c       |   22 +-
 external/mit/lua/dist/src/lua.h       |   24 +-
 external/mit/lua/dist/src/luac.c      |    8 +-
 external/mit/lua/dist/src/luaconf.h   |   78 ++++--
 external/mit/lua/dist/src/lualib.h    |    4 +-
 external/mit/lua/dist/src/lundump.c   |   28 +-
 external/mit/lua/dist/src/lundump.h   |    7 +-
 external/mit/lua/dist/src/lutf8lib.c  |    4 +-
 external/mit/lua/dist/src/lvm.c       |  288 ++++++++++++++-----------
 external/mit/lua/dist/src/lvm.h       |   60 ++++-
 external/mit/lua/dist/src/lzio.c      |   16 +-
 external/mit/lua/dist/src/lzio.h      |    5 +-
 66 files changed, 1658 insertions(+), 1131 deletions(-)

diffs (truncated from 6727 to 300 lines):

diff -r dd557e23e325 -r 06e11b09a7de external/mit/lua/dist/Makefile
--- a/external/mit/lua/dist/Makefile    Thu Jan 28 10:20:40 2016 +0000
+++ b/external/mit/lua/dist/Makefile    Thu Jan 28 14:41:39 2016 +0000
@@ -46,7 +46,7 @@
 
 # Lua version and release.
 V= 5.3
-R= $V.1
+R= $V.2
 
 # Targets start here.
 all:   $(PLAT)
diff -r dd557e23e325 -r 06e11b09a7de external/mit/lua/dist/README
--- a/external/mit/lua/dist/README      Thu Jan 28 10:20:40 2016 +0000
+++ b/external/mit/lua/dist/README      Thu Jan 28 14:41:39 2016 +0000
@@ -1,5 +1,5 @@
 
-This is Lua 5.3.1, released on 10 Jun 2015.
+This is Lua 5.3.2, released on 25 Nov 2015.
 
 For installation instructions, license details, and
 further information about Lua, see doc/readme.html.
diff -r dd557e23e325 -r 06e11b09a7de external/mit/lua/dist/doc/lua.1
--- a/external/mit/lua/dist/doc/lua.1   Thu Jan 28 10:20:40 2016 +0000
+++ b/external/mit/lua/dist/doc/lua.1   Thu Jan 28 14:41:39 2016 +0000
@@ -1,4 +1,4 @@
-.\"    $NetBSD: lua.1,v 1.3 2015/02/02 14:03:05 lneto Exp $
+.\"    $NetBSD: lua.1,v 1.4 2016/01/28 14:41:39 lneto Exp $
 .\"
 .TH LUA 1 "Date: 2014/12/10 15:55:45 "
 .SH NAME
diff -r dd557e23e325 -r 06e11b09a7de external/mit/lua/dist/doc/lua.css
--- a/external/mit/lua/dist/doc/lua.css Thu Jan 28 10:20:40 2016 +0000
+++ b/external/mit/lua/dist/doc/lua.css Thu Jan 28 14:41:39 2016 +0000
@@ -131,3 +131,29 @@
 p.logos a:link:hover, p.logos a:visited:hover {
        background-color: inherit ;
 }
+
+table.book {
+       border: none ;
+       border-spacing: 0 ;
+       border-collapse: collapse ;
+}
+
+table.book td {
+       padding: 0 ;
+       vertical-align: top ;
+}
+
+table.book td.cover {
+       padding-right: 1em ;
+}
+
+table.book img {
+       border: solid #000080 1px ;
+}
+
+table.book span {
+       font-size: small ;
+       text-align: left ;
+       display: block ;
+       margin-top: 0.25em ;
+}
diff -r dd557e23e325 -r 06e11b09a7de external/mit/lua/dist/doc/luac.1
--- a/external/mit/lua/dist/doc/luac.1  Thu Jan 28 10:20:40 2016 +0000
+++ b/external/mit/lua/dist/doc/luac.1  Thu Jan 28 14:41:39 2016 +0000
@@ -1,7 +1,7 @@
-.\"    $NetBSD: luac.1,v 1.2 2014/07/19 18:38:33 lneto Exp $
+.\"    $NetBSD: luac.1,v 1.3 2016/01/28 14:41:39 lneto Exp $
 .\"
-.\" $Id: luac.1,v 1.2 2014/07/19 18:38:33 lneto Exp $
-.TH LUAC 1 "$Date: 2014/07/19 18:38:33 $"
+.\" Id: luac.man,v 1.29 2011/11/16 13:53:40 lhf Exp 
+.TH LUAC 1 "Date: 2011/11/16 13:53:40 "
 .SH NAME
 luac \- Lua compiler
 .SH SYNOPSIS
diff -r dd557e23e325 -r 06e11b09a7de external/mit/lua/dist/doc/manual.html
--- a/external/mit/lua/dist/doc/manual.html     Thu Jan 28 10:20:40 2016 +0000
+++ b/external/mit/lua/dist/doc/manual.html     Thu Jan 28 14:41:39 2016 +0000
@@ -35,7 +35,7 @@
 <!-- ====================================================================== -->
 <p>
 
-<!-- Id: manual.of,v 1.151 2015/06/10 21:08:57 roberto Exp  -->
+<!-- Id: manual.of,v 1.153 2015/11/25 16:57:42 roberto Exp  -->
 
 
 
@@ -398,7 +398,7 @@
 using the <a href="#pdf-setmetatable"><code>setmetatable</code></a> function.
 You cannot change the metatable of other types from Lua code
 (except by using the debug library (<a href="#6.10">&sect;6.10</a>));
-you must use the C&nbsp;API for that.
+you should use the C&nbsp;API for that.
 
 
 <p>
@@ -589,7 +589,7 @@
 the <code>&lt;=</code> (less equal) operation.
 
 Unlike other operations,
-The less-equal operation can use two different events.
+the less-equal operation can use two different events.
 First, Lua looks for the "<code>__le</code>" metamethod in both operands,
 like in the "lt" operation.
 If it cannot find such a metamethod,
@@ -1051,7 +1051,8 @@
 (also called <em>identifiers</em>)
 in Lua can be any string of letters,
 digits, and underscores,
-not beginning with a digit.
+not beginning with a digit and
+not being a reserved word.
 Identifiers are used to name variables, table fields, and labels.
 
 
@@ -2706,7 +2707,9 @@
 <code>lua_upvalueindex(1)</code>, and so on.
 Any access to <code>lua_upvalueindex(<em>n</em>)</code>,
 where <em>n</em> is greater than the number of upvalues of the
-current function (but not greater than 256),
+current function
+(but not greater than 256,
+which is one plus the maximum number of upvalues in a closure),
 produces an acceptable but invalid index.
 
 
@@ -2971,6 +2974,7 @@
 The third field, <code>x</code>,
 tells whether the function may raise errors:
 '<code>-</code>' means the function never raises any error;
+'<code>m</code>' means the function may raise memory errors;
 '<code>e</code>' means the function may raise errors;
 '<code>v</code>' means the function may raise an error on purpose.
 
@@ -3143,7 +3147,8 @@
 The number of results is adjusted to <code>nresults</code>,
 unless <code>nresults</code> is <a name="pdf-LUA_MULTRET"><code>LUA_MULTRET</code></a>.
 In this case, all results from the function are pushed.
-Lua takes care that the returned values fit into the stack space.
+Lua takes care that the returned values fit into the stack space,
+but it does not ensure any extra space in the stack.
 The function results are pushed onto the stack in direct order
 (the first result is pushed first),
 so that after the call the last result is on the top of the stack.
@@ -3253,14 +3258,15 @@
 <pre>int lua_checkstack (lua_State *L, int n);</pre>
 
 <p>
-Ensures that the stack has space for at least <code>n</code> extra slots.
+Ensures that the stack has space for at least <code>n</code> extra slots
+(that is, that you can safely push up to <code>n</code> values into it).
 It returns false if it cannot fulfill the request,
 either because it would cause the stack
 to be larger than a fixed maximum size
 (typically at least several thousand elements) or
 because it cannot allocate memory for the extra space.
 This function never shrinks the stack;
-if the stack is already larger than the new size,
+if the stack already has space for the extra slots,
 it is left unchanged.
 
 
@@ -3345,7 +3351,7 @@
 
 
 <hr><h3><a name="lua_createtable"><code>lua_createtable</code></a></h3><p>
-<span class="apii">[-0, +1, <em>e</em>]</span>
+<span class="apii">[-0, +1, <em>m</em>]</span>
 <pre>void lua_createtable (lua_State *L, int narr, int nrec);</pre>
 
 <p>
@@ -3355,7 +3361,7 @@
 parameter <code>nrec</code> is a hint for how many other elements
 the table will have.
 Lua may use these hints to preallocate memory for the new table.
-This pre-allocation is useful for performance when you know in advance
+This preallocation is useful for performance when you know in advance
 how many elements the table will have.
 Otherwise you can use the function <a href="#lua_newtable"><code>lua_newtable</code></a>.
 
@@ -3364,7 +3370,7 @@
 
 
 <hr><h3><a name="lua_dump"><code>lua_dump</code></a></h3><p>
-<span class="apii">[-0, +0, <em>e</em>]</span>
+<span class="apii">[-0, +0, &ndash;]</span>
 <pre>int lua_dump (lua_State *L,
                         lua_Writer writer,
                         void *data,
@@ -3978,7 +3984,7 @@
 
 
 <hr><h3><a name="lua_newtable"><code>lua_newtable</code></a></h3><p>
-<span class="apii">[-0, +1, <em>e</em>]</span>
+<span class="apii">[-0, +1, <em>m</em>]</span>
 <pre>void lua_newtable (lua_State *L);</pre>
 
 <p>
@@ -3990,7 +3996,7 @@
 
 
 <hr><h3><a name="lua_newthread"><code>lua_newthread</code></a></h3><p>
-<span class="apii">[-0, +1, <em>e</em>]</span>
+<span class="apii">[-0, +1, <em>m</em>]</span>
 <pre>lua_State *lua_newthread (lua_State *L);</pre>
 
 <p>
@@ -4011,7 +4017,7 @@
 
 
 <hr><h3><a name="lua_newuserdata"><code>lua_newuserdata</code></a></h3><p>
-<span class="apii">[-0, +1, <em>e</em>]</span>
+<span class="apii">[-0, +1, <em>m</em>]</span>
 <pre>void *lua_newuserdata (lua_State *L, size_t size);</pre>
 
 <p>
@@ -4221,7 +4227,7 @@
 
 
 <hr><h3><a name="lua_pushcclosure"><code>lua_pushcclosure</code></a></h3><p>
-<span class="apii">[-n, +1, <em>e</em>]</span>
+<span class="apii">[-n, +1, <em>m</em>]</span>
 <pre>void lua_pushcclosure (lua_State *L, lua_CFunction fn, int n);</pre>
 
 <p>
@@ -4278,7 +4284,7 @@
 
 
 <hr><h3><a name="lua_pushfstring"><code>lua_pushfstring</code></a></h3><p>
-<span class="apii">[-0, +1, <em>e</em>]</span>
+<span class="apii">[-0, +1, <em>m</em>]</span>
 <pre>const char *lua_pushfstring (lua_State *L, const char *fmt, ...);</pre>
 
 <p>
@@ -4358,7 +4364,7 @@
 
 
 <hr><h3><a name="lua_pushliteral"><code>lua_pushliteral</code></a></h3><p>
-<span class="apii">[-0, +1, <em>e</em>]</span>
+<span class="apii">[-0, +1, <em>m</em>]</span>
 <pre>const char *lua_pushliteral (lua_State *L, const char *s);</pre>
 
 <p>
@@ -4370,7 +4376,7 @@
 
 
 <hr><h3><a name="lua_pushlstring"><code>lua_pushlstring</code></a></h3><p>
-<span class="apii">[-0, +1, <em>e</em>]</span>
+<span class="apii">[-0, +1, <em>m</em>]</span>
 <pre>const char *lua_pushlstring (lua_State *L, const char *s, size_t len);</pre>
 
 <p>
@@ -4413,7 +4419,7 @@
 
 
 <hr><h3><a name="lua_pushstring"><code>lua_pushstring</code></a></h3><p>
-<span class="apii">[-0, +1, <em>e</em>]</span>
+<span class="apii">[-0, +1, <em>m</em>]</span>
 <pre>const char *lua_pushstring (lua_State *L, const char *s);</pre>
 
 <p>
@@ -4460,7 +4466,7 @@
 
 
 <hr><h3><a name="lua_pushvfstring"><code>lua_pushvfstring</code></a></h3><p>
-<span class="apii">[-0, +1, <em>e</em>]</span>
+<span class="apii">[-0, +1, <em>m</em>]</span>
 <pre>const char *lua_pushvfstring (lua_State *L,
                               const char *fmt,
                               va_list argp);</pre>
@@ -4555,7 +4561,7 @@
 
 
 <hr><h3><a name="lua_rawset"><code>lua_rawset</code></a></h3><p>
-<span class="apii">[-2, +0, <em>e</em>]</span>
+<span class="apii">[-2, +0, <em>m</em>]</span>
 <pre>void lua_rawset (lua_State *L, int index);</pre>
 
 <p>
@@ -4567,7 +4573,7 @@
 
 
 <hr><h3><a name="lua_rawseti"><code>lua_rawseti</code></a></h3><p>
-<span class="apii">[-1, +0, <em>e</em>]</span>
+<span class="apii">[-1, +0, <em>m</em>]</span>
 <pre>void lua_rawseti (lua_State *L, int index, lua_Integer i);</pre>
 
 <p>
@@ -4586,7 +4592,7 @@
 
 
 <hr><h3><a name="lua_rawsetp"><code>lua_rawsetp</code></a></h3><p>
-<span class="apii">[-1, +0, <em>e</em>]</span>
+<span class="apii">[-1, +0, <em>m</em>]</span>
 <pre>void lua_rawsetp (lua_State *L, int index, const void *p);</pre>
 
 <p>



Home | Main Index | Thread Index | Old Index