Module Name:    src
Committed By:   alnsn
Date:           Sat Aug  4 17:30:01 UTC 2018

Modified Files:
        src/external/mit/lua/dist: README
        src/external/mit/lua/dist/doc: contents.html lua.css manual.html
            readme.html
        src/external/mit/lua/dist/src: Makefile lapi.c lapi.h lauxlib.c
            lauxlib.h lbaselib.c lbitlib.c lcode.c lcode.h lcorolib.c lctype.c
            lctype.h ldblib.c ldebug.c ldebug.h ldo.c ldo.h ldump.c lfunc.c
            lfunc.h lgc.c lgc.h linit.c liolib.c llex.c llex.h llimits.h
            lmathlib.c lmem.c lmem.h loadlib.c lobject.c lobject.h lopcodes.c
            lopcodes.h loslib.c lparser.c lparser.h lprefix.h lstate.c lstate.h
            lstring.c lstring.h lstrlib.c ltable.c ltable.h ltablib.c ltm.c
            ltm.h lua.c lua.h luac.c luaconf.h lualib.h lundump.c lundump.h
            lutf8lib.c lvm.c lvm.h lzio.c lzio.h

Log Message:
Resolve conflicts.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/external/mit/lua/dist/README
cvs rdiff -u -r1.6 -r1.7 src/external/mit/lua/dist/doc/contents.html \
    src/external/mit/lua/dist/doc/lua.css \
    src/external/mit/lua/dist/doc/readme.html
cvs rdiff -u -r1.7 -r1.8 src/external/mit/lua/dist/doc/manual.html
cvs rdiff -u -r1.4 -r1.5 src/external/mit/lua/dist/src/Makefile
cvs rdiff -u -r1.10 -r1.11 src/external/mit/lua/dist/src/lapi.c \
    src/external/mit/lua/dist/src/lauxlib.c \
    src/external/mit/lua/dist/src/lcode.c \
    src/external/mit/lua/dist/src/ldblib.c \
    src/external/mit/lua/dist/src/ldebug.c \
    src/external/mit/lua/dist/src/loslib.c \
    src/external/mit/lua/dist/src/lparser.c \
    src/external/mit/lua/dist/src/ltable.c \
    src/external/mit/lua/dist/src/lua.h
cvs rdiff -u -r1.8 -r1.9 src/external/mit/lua/dist/src/lapi.h \
    src/external/mit/lua/dist/src/ldebug.h \
    src/external/mit/lua/dist/src/ldo.c src/external/mit/lua/dist/src/ldo.h \
    src/external/mit/lua/dist/src/ldump.c \
    src/external/mit/lua/dist/src/linit.c \
    src/external/mit/lua/dist/src/liolib.c \
    src/external/mit/lua/dist/src/lmathlib.c \
    src/external/mit/lua/dist/src/lmem.c \
    src/external/mit/lua/dist/src/loadlib.c \
    src/external/mit/lua/dist/src/lstate.c \
    src/external/mit/lua/dist/src/lstate.h \
    src/external/mit/lua/dist/src/lstring.c \
    src/external/mit/lua/dist/src/lstring.h \
    src/external/mit/lua/dist/src/ltablib.c \
    src/external/mit/lua/dist/src/ltm.c src/external/mit/lua/dist/src/lua.c
cvs rdiff -u -r1.7 -r1.8 src/external/mit/lua/dist/src/lauxlib.h \
    src/external/mit/lua/dist/src/lcode.h \
    src/external/mit/lua/dist/src/lfunc.c \
    src/external/mit/lua/dist/src/lfunc.h src/external/mit/lua/dist/src/lgc.h \
    src/external/mit/lua/dist/src/llex.h src/external/mit/lua/dist/src/lmem.h \
    src/external/mit/lua/dist/src/lopcodes.c \
    src/external/mit/lua/dist/src/lopcodes.h \
    src/external/mit/lua/dist/src/lparser.h \
    src/external/mit/lua/dist/src/ltable.h \
    src/external/mit/lua/dist/src/ltm.h \
    src/external/mit/lua/dist/src/lundump.c \
    src/external/mit/lua/dist/src/lutf8lib.c \
    src/external/mit/lua/dist/src/lzio.c src/external/mit/lua/dist/src/lzio.h
cvs rdiff -u -r1.9 -r1.10 src/external/mit/lua/dist/src/lbaselib.c \
    src/external/mit/lua/dist/src/lgc.c \
    src/external/mit/lua/dist/src/llimits.h \
    src/external/mit/lua/dist/src/lobject.h \
    src/external/mit/lua/dist/src/luac.c src/external/mit/lua/dist/src/lvm.h
cvs rdiff -u -r1.6 -r1.7 src/external/mit/lua/dist/src/lbitlib.c \
    src/external/mit/lua/dist/src/lcorolib.c \
    src/external/mit/lua/dist/src/lctype.c \
    src/external/mit/lua/dist/src/lctype.h \
    src/external/mit/lua/dist/src/lprefix.h \
    src/external/mit/lua/dist/src/lualib.h \
    src/external/mit/lua/dist/src/lundump.h
cvs rdiff -u -r1.11 -r1.12 src/external/mit/lua/dist/src/llex.c \
    src/external/mit/lua/dist/src/lobject.c
cvs rdiff -u -r1.17 -r1.18 src/external/mit/lua/dist/src/lstrlib.c
cvs rdiff -u -r1.22 -r1.23 src/external/mit/lua/dist/src/luaconf.h
cvs rdiff -u -r1.13 -r1.14 src/external/mit/lua/dist/src/lvm.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/mit/lua/dist/README
diff -u src/external/mit/lua/dist/README:1.7 src/external/mit/lua/dist/README:1.8
--- src/external/mit/lua/dist/README:1.7	Wed Apr 26 13:06:22 2017
+++ src/external/mit/lua/dist/README	Sat Aug  4 17:30:01 2018
@@ -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.

Index: src/external/mit/lua/dist/doc/contents.html
diff -u src/external/mit/lua/dist/doc/contents.html:1.6 src/external/mit/lua/dist/doc/contents.html:1.7
--- src/external/mit/lua/dist/doc/contents.html:1.6	Wed Apr 26 12:36:53 2017
+++ src/external/mit/lua/dist/doc/contents.html	Sat Aug  4 17:30:01 2018
@@ -32,7 +32,7 @@ For a complete introduction to Lua progr
 
 <P>
 <SMALL>
-Copyright &copy; 2015&ndash;2017 Lua.org, PUC-Rio.
+Copyright &copy; 2015&ndash;2018 Lua.org, PUC-Rio.
 Freely available under the terms of the
 <A HREF="http://www.lua.org/license.html";>Lua license</A>.
 </SMALL>
@@ -609,10 +609,10 @@ Freely available under the terms of the
 
 <P CLASS="footer">
 Last update:
-Thu Dec 22 18:29:39 BRST 2016
+Mon Jun 18 22:56:06 -03 2018
 </P>
 <!--
-Last change: revised for Lua 5.3.4
+Last change: revised for Lua 5.3.5
 -->
 
 </BODY>
Index: src/external/mit/lua/dist/doc/lua.css
diff -u src/external/mit/lua/dist/doc/lua.css:1.6 src/external/mit/lua/dist/doc/lua.css:1.7
--- src/external/mit/lua/dist/doc/lua.css:1.6	Thu Sep  8 02:21:31 2016
+++ src/external/mit/lua/dist/doc/lua.css	Sat Aug  4 17:30:01 2018
@@ -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 ;
 }
Index: src/external/mit/lua/dist/doc/readme.html
diff -u src/external/mit/lua/dist/doc/readme.html:1.6 src/external/mit/lua/dist/doc/readme.html:1.7
--- src/external/mit/lua/dist/doc/readme.html:1.6	Wed Apr 26 12:36:53 2017
+++ src/external/mit/lua/dist/doc/readme.html	Sat Aug  4 17:30:01 2018
@@ -107,7 +107,7 @@ Here are the details.
 <OL>
 <LI>
 Open a terminal window and move to
-the top-level directory, which is named <TT>lua-5.3.x</TT>.
+the top-level directory, which is named <TT>lua-5.3.5</TT>.
 The <TT>Makefile</TT> there controls both the build process and the installation process.
 <P>
 <LI>
@@ -355,10 +355,10 @@ THE SOFTWARE.
 
 <P CLASS="footer">
 Last update:
-Thu Dec 22 18:22:57 BRST 2016
+Mon Jun 18 22:57:33 -03 2018
 </P>
 <!--
-Last change: revised for Lua 5.3.4
+Last change: revised for Lua 5.3.5
 -->
 
 </BODY>

Index: src/external/mit/lua/dist/doc/manual.html
diff -u src/external/mit/lua/dist/doc/manual.html:1.7 src/external/mit/lua/dist/doc/manual.html:1.8
--- src/external/mit/lua/dist/doc/manual.html:1.7	Wed Apr 26 12:36:53 2017
+++ src/external/mit/lua/dist/doc/manual.html	Sat Aug  4 17:30:01 2018
@@ -19,7 +19,7 @@ by Roberto Ierusalimschy, Luiz Henrique 
 
 <P>
 <SMALL>
-Copyright &copy; 2015&ndash;2017 Lua.org, PUC-Rio.
+Copyright &copy; 2015&ndash;2018 Lua.org, PUC-Rio.
 Freely available under the terms of the
 <a href="http://www.lua.org/license.html";>Lua license</a>.
 </SMALL>
@@ -35,7 +35,7 @@ Freely available under the terms of the
 <!-- ====================================================================== -->
 <p>
 
-<!-- Id: manual.of,v 1.167 2017/01/09 15:18:11 roberto Exp  -->
+<!-- Id: manual.of,v 1.167.1.2 2018/06/26 15:49:07 roberto Exp  -->
 
 
 
@@ -203,8 +203,8 @@ even those that do not support threads n
 
 <p>
 The type <em>table</em> implements associative arrays,
-that is, arrays that can be indexed not only with numbers,
-but with any Lua value except <b>nil</b> and NaN.
+that is, arrays that can have as indices not only numbers,
+but any Lua value except <b>nil</b> and NaN.
 (<em>Not a Number</em> is a special value used to represent
 undefined or unrepresentable numerical results, such as <code>0/0</code>.)
 Tables can be <em>heterogeneous</em>;
@@ -400,6 +400,8 @@ with the event name prefixed by two unde
 the corresponding values are called <em>metamethods</em>.
 In the previous example, the key is "<code>__add</code>"
 and the metamethod is the function that performs the addition.
+Unless stated otherwise,
+metamethods should be function values.
 
 
 <p>
@@ -597,7 +599,7 @@ it is also slower than a real <code>__le
 </li>
 
 <li><b><code>__index</code>: </b>
-The indexing access <code>table[key]</code>.
+The indexing access operation <code>table[key]</code>.
 This event happens when <code>table</code> is not a table or
 when <code>key</code> is not present in <code>table</code>.
 The metamethod is looked up in <code>table</code>.
@@ -1276,13 +1278,8 @@ Square brackets are used to index a tabl
 <pre>
 	var ::= prefixexp &lsquo;<b>[</b>&rsquo; exp &lsquo;<b>]</b>&rsquo;
 </pre><p>
-The meaning of accesses to table fields can be changed via metatables.
-An access to an indexed variable <code>t[i]</code> is equivalent to
-a call <code>gettable_event(t,i)</code>.
-(See <a href="#2.4">&sect;2.4</a> for a complete description of the
-<code>gettable_event</code> 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 <a href="#2.4">&sect;2.4</a>).
 
 
 <p>
@@ -1477,22 +1474,17 @@ cyclically permutes the values of <code>
 
 
 <p>
-The meaning of assignments to global variables
-and table fields can be changed via metatables.
-An assignment to an indexed variable <code>t[i] = val</code> is equivalent to
-<code>settable_event(t,i,val)</code>.
-(See <a href="#2.4">&sect;2.4</a> for a complete description of the
-<code>settable_event</code> function.
-This function is not defined or callable in Lua.
-We use it here only for explanatory purposes.)
-
-
-<p>
 An assignment to a global name <code>x = val</code>
 is equivalent to the assignment
 <code>_ENV.x = val</code> (see <a href="#2.2">&sect;2.2</a>).
 
 
+<p>
+The meaning of assignments to table fields and
+global variables (which are actually table fields, too)
+can be changed via metatables (see <a href="#2.4">&sect;2.4</a>).
+
+
 
 
 
@@ -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
 </pre>
 
@@ -2039,9 +2031,12 @@ two objects are considered equal only if
 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).
 
 
 <p>
@@ -2303,7 +2298,7 @@ If the value of prefixexp has type <em>f
 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 <a href="#2.4">&sect;2.4</a>).
 
@@ -2881,7 +2876,7 @@ it can do whatever it wants on that Lua 
 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 <a href="#lua_newthread"><code>lua_newthread</code></a>),
 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 <a href
 
 
 <p>
-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 <code>what</code> string with the character '<code>&gt;</code>'.
 (In that case,
 <code>lua_getinfo</code> pops the function from the top of the stack.)
@@ -6462,7 +6457,7 @@ file-related functions in the standard l
 
 <p>
 Pushes onto the stack the field <code>e</code> from the metatable
-of the object at index <code>obj</code> and returns the type of pushed value.
+of the object at index <code>obj</code> 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 <code>LUA_TNIL</code>.
@@ -6749,7 +6744,7 @@ In words, if the argument <code>arg</cod
 the macro results in the default <code>dflt</code>.
 Otherwise, it results in the result of calling <code>func</code>
 with the state <code>L</code> and the argument index <code>arg</code> as
-parameters.
+arguments.
 Note that it evaluates the expression <code>dflt</code> only if needed.
 
 
@@ -8680,7 +8675,7 @@ the lowercase letters plus the '<code>-<
 <p>
 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 <code>a2</
 
 
 <p>
-Returns a new table with all parameters stored into keys 1, 2, etc.
-and with a field "<code>n</code>" with the total number of parameters.
+Returns a new table with all arguments stored into keys 1, 2, etc.
+and with a field "<code>n</code>" 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 <code>x</code> (
 <p>
 
 Returns the arc tangent of <code>y/x</code> (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 <code>x</code> being zero.)
 
@@ -9516,7 +9511,7 @@ all I/O functions return <b>nil</b> on f
 (plus an error message as a second result and
 a system-dependent error code as a third result)
 and some value different from <b>nil</b> 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 t
 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
 The call <code>io.lines()</code> (with no file name) is equivalent
 to <code>io.input():lines("*l")</code>;
 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.
 
 
 <p>
@@ -9963,7 +9958,7 @@ the host system and on the current local
 
 
 <p>
-On non-POSIX systems,
+In non-POSIX systems,
 this function may be not thread safe
 because of its reliance on C&nbsp;function <code>gmtime</code> and C&nbsp;function <code>localtime</code>.
 
@@ -10163,7 +10158,7 @@ and explicitly removed when no longer ne
 
 
 <p>
-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 ha
 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 <b>nil</b> if there is no variable with the given index,
 and raises an error when called with a level out of range.
 (You can call <a href="#pdf-debug.getinfo"><code>debug.getinfo</code></a> to check whether the level is valid.)
@@ -10400,7 +10395,7 @@ When called without arguments,
 
 
 <p>
-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:
 <code>"call"</code> (or <code>"tail call"</code>),
 <code>"return"</code>,
@@ -10551,7 +10546,8 @@ The options are:
 
 <ul>
 <li><b><code>-e <em>stat</em></code>: </b> executes string <em>stat</em>;</li>
-<li><b><code>-l <em>mod</em></code>: </b> "requires" <em>mod</em>;</li>
+<li><b><code>-l <em>mod</em></code>: </b> "requires" <em>mod</em> and assigns the
+  result to global @<em>mod</em>;</li>
 <li><b><code>-i</code>: </b> enters interactive mode after running <em>script</em>;</li>
 <li><b><code>-v</code>: </b> prints version information;</li>
 <li><b><code>-E</code>: </b> ignores environment variables;</li>
@@ -10629,7 +10625,7 @@ For instance, the call
 </pre><p>
 will print "<code>-e</code>".
 If there is a script,
-the script is called with parameters
+the script is called with arguments
 <code>arg[1]</code>, &middot;&middot;&middot;, <code>arg[#arg]</code>.
 (Like all chunks in Lua,
 the script is compiled as a vararg function.)
@@ -10815,7 +10811,7 @@ The following functions were deprecated 
 <code>frexp</code>, and <code>ldexp</code>.
 You can replace <code>math.pow(x,y)</code> with <code>x^y</code>;
 you can replace <code>math.atan2</code> with <code>math.atan</code>,
-which now accepts one or two parameters;
+which now accepts one or two arguments;
 you can replace <code>math.ldexp(x,exp)</code> with <code>x * 2.0^exp</code>.
 For the other operations,
 you can either use an external library or
@@ -10850,7 +10846,7 @@ of the first result.)
 <ul>
 
 <li>
-Continuation functions now receive as parameters what they needed
+Continuation functions now receive as arguments what they needed
 to get through <code>lua_getctx</code>,
 so <code>lua_getctx</code> has been removed.
 Adapt your code accordingly.
@@ -10973,12 +10969,13 @@ and LiteralString, see <a href="#3.1">&s
 
 
 
+
 <P CLASS="footer">
 Last update:
-Mon Jan  9 13:30:53 BRST 2017
+Tue Jun 26 13:16:37 -03 2018
 </P>
 <!--
-Last change: revised for Lua 5.3.4
+Last change: revised for Lua 5.3.5
 -->
 
 </body></html>

Index: src/external/mit/lua/dist/src/Makefile
diff -u src/external/mit/lua/dist/src/Makefile:1.4 src/external/mit/lua/dist/src/Makefile:1.5
--- src/external/mit/lua/dist/src/Makefile:1.4	Thu Oct  8 13:21:00 2015
+++ src/external/mit/lua/dist/src/Makefile	Sat Aug  4 17:30:01 2018
@@ -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" \

Index: src/external/mit/lua/dist/src/lapi.c
diff -u src/external/mit/lua/dist/src/lapi.c:1.10 src/external/mit/lua/dist/src/lapi.c:1.11
--- src/external/mit/lua/dist/src/lapi.c:1.10	Wed Dec 13 13:00:14 2017
+++ src/external/mit/lua/dist/src/lapi.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lapi.c,v 1.10 2017/12/13 13:00:14 mbalmer Exp $	*/
+/*	$NetBSD: lapi.c,v 1.11 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lauxlib.c
diff -u src/external/mit/lua/dist/src/lauxlib.c:1.10 src/external/mit/lua/dist/src/lauxlib.c:1.11
--- src/external/mit/lua/dist/src/lauxlib.c:1.10	Wed Apr 26 13:53:18 2017
+++ src/external/mit/lua/dist/src/lauxlib.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lauxlib.c,v 1.10 2017/04/26 13:53:18 mbalmer Exp $	*/
+/*	$NetBSD: lauxlib.c,v 1.11 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lcode.c
diff -u src/external/mit/lua/dist/src/lcode.c:1.10 src/external/mit/lua/dist/src/lcode.c:1.11
--- src/external/mit/lua/dist/src/lcode.c:1.10	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lcode.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lcode.c,v 1.10 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lcode.c,v 1.11 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/ldblib.c
diff -u src/external/mit/lua/dist/src/ldblib.c:1.10 src/external/mit/lua/dist/src/ldblib.c:1.11
--- src/external/mit/lua/dist/src/ldblib.c:1.10	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/ldblib.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: ldblib.c,v 1.10 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: ldblib.c,v 1.11 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/ldebug.c
diff -u src/external/mit/lua/dist/src/ldebug.c:1.10 src/external/mit/lua/dist/src/ldebug.c:1.11
--- src/external/mit/lua/dist/src/ldebug.c:1.10	Thu Aug  3 13:40:07 2017
+++ src/external/mit/lua/dist/src/ldebug.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: ldebug.c,v 1.10 2017/08/03 13:40:07 mbalmer Exp $	*/
+/*	$NetBSD: ldebug.c,v 1.11 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/loslib.c
diff -u src/external/mit/lua/dist/src/loslib.c:1.10 src/external/mit/lua/dist/src/loslib.c:1.11
--- src/external/mit/lua/dist/src/loslib.c:1.10	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/loslib.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: loslib.c,v 1.10 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: loslib.c,v 1.11 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
@@ -295,7 +295,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);
@@ -342,7 +343,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;
 }
Index: src/external/mit/lua/dist/src/lparser.c
diff -u src/external/mit/lua/dist/src/lparser.c:1.10 src/external/mit/lua/dist/src/lparser.c:1.11
--- src/external/mit/lua/dist/src/lparser.c:1.10	Sun May  7 08:14:06 2017
+++ src/external/mit/lua/dist/src/lparser.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lparser.c,v 1.10 2017/05/07 08:14:06 mbalmer Exp $	*/
+/*	$NetBSD: lparser.c,v 1.11 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/ltable.c
diff -u src/external/mit/lua/dist/src/ltable.c:1.10 src/external/mit/lua/dist/src/ltable.c:1.11
--- src/external/mit/lua/dist/src/ltable.c:1.10	Sun Jul  1 10:08:38 2018
+++ src/external/mit/lua/dist/src/ltable.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: ltable.c,v 1.10 2018/07/01 10:08:38 mbalmer Exp $	*/
+/*	$NetBSD: ltable.c,v 1.11 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
@@ -231,7 +231,9 @@ static unsigned int computesizes (unsign
   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? */
@@ -641,13 +643,13 @@ void luaH_setint (lua_State *L, Table *t
 }
 
 
-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++;
@@ -657,7 +659,7 @@ static int unbound_search (Table *t, uns
   }
   /* 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;
   }
@@ -669,7 +671,7 @@ static int unbound_search (Table *t, uns
 ** 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 */
Index: src/external/mit/lua/dist/src/lua.h
diff -u src/external/mit/lua/dist/src/lua.h:1.10 src/external/mit/lua/dist/src/lua.h:1.11
--- src/external/mit/lua/dist/src/lua.h:1.10	Sat May 20 10:12:29 2017
+++ src/external/mit/lua/dist/src/lua.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lua.h,v 1.10 2017/05/20 10:12:29 mbalmer Exp $	*/
+/*	$NetBSD: lua.h,v 1.11 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
@@ -23,11 +23,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"
 
 
@@ -486,7 +486,7 @@ struct lua_Debug {
 #ifdef _KERNEL
 * Copyright (c) 2016-2017, Lourival Vieira Neto <ln...@netbsd.org>.
 #endif
-* 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

Index: src/external/mit/lua/dist/src/lapi.h
diff -u src/external/mit/lua/dist/src/lapi.h:1.8 src/external/mit/lua/dist/src/lapi.h:1.9
--- src/external/mit/lua/dist/src/lapi.h:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lapi.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lapi.h,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lapi.h,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/ldebug.h
diff -u src/external/mit/lua/dist/src/ldebug.h:1.8 src/external/mit/lua/dist/src/ldebug.h:1.9
--- src/external/mit/lua/dist/src/ldebug.h:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/ldebug.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: ldebug.h,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: ldebug.h,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/ldo.c
diff -u src/external/mit/lua/dist/src/ldo.c:1.8 src/external/mit/lua/dist/src/ldo.c:1.9
--- src/external/mit/lua/dist/src/ldo.c:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/ldo.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: ldo.c,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: ldo.c,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/ldo.h
diff -u src/external/mit/lua/dist/src/ldo.h:1.8 src/external/mit/lua/dist/src/ldo.h:1.9
--- src/external/mit/lua/dist/src/ldo.h:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/ldo.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: ldo.h,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: ldo.h,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/ldump.c
diff -u src/external/mit/lua/dist/src/ldump.c:1.8 src/external/mit/lua/dist/src/ldump.c:1.9
--- src/external/mit/lua/dist/src/ldump.c:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/ldump.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: ldump.c,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: ldump.c,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/linit.c
diff -u src/external/mit/lua/dist/src/linit.c:1.8 src/external/mit/lua/dist/src/linit.c:1.9
--- src/external/mit/lua/dist/src/linit.c:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/linit.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: linit.c,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: linit.c,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/liolib.c
diff -u src/external/mit/lua/dist/src/liolib.c:1.8 src/external/mit/lua/dist/src/liolib.c:1.9
--- src/external/mit/lua/dist/src/liolib.c:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/liolib.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: liolib.c,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: liolib.c,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
@@ -208,11 +208,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);
 }
 
 
@@ -714,7 +719,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},
Index: src/external/mit/lua/dist/src/lmathlib.c
diff -u src/external/mit/lua/dist/src/lmathlib.c:1.8 src/external/mit/lua/dist/src/lmathlib.c:1.9
--- src/external/mit/lua/dist/src/lmathlib.c:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lmathlib.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lmathlib.c,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lmathlib.c,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lmem.c
diff -u src/external/mit/lua/dist/src/lmem.c:1.8 src/external/mit/lua/dist/src/lmem.c:1.9
--- src/external/mit/lua/dist/src/lmem.c:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lmem.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lmem.c,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lmem.c,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/loadlib.c
diff -u src/external/mit/lua/dist/src/loadlib.c:1.8 src/external/mit/lua/dist/src/loadlib.c:1.9
--- src/external/mit/lua/dist/src/loadlib.c:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/loadlib.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: loadlib.c,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: loadlib.c,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 **
Index: src/external/mit/lua/dist/src/lstate.c
diff -u src/external/mit/lua/dist/src/lstate.c:1.8 src/external/mit/lua/dist/src/lstate.c:1.9
--- src/external/mit/lua/dist/src/lstate.c:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lstate.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lstate.c,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lstate.c,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lstate.h
diff -u src/external/mit/lua/dist/src/lstate.h:1.8 src/external/mit/lua/dist/src/lstate.h:1.9
--- src/external/mit/lua/dist/src/lstate.h:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lstate.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lstate.h,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lstate.h,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
@@ -28,6 +28,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.
 
 */
 
Index: src/external/mit/lua/dist/src/lstring.c
diff -u src/external/mit/lua/dist/src/lstring.c:1.8 src/external/mit/lua/dist/src/lstring.c:1.9
--- src/external/mit/lua/dist/src/lstring.c:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lstring.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lstring.c,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lstring.c,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lstring.h
diff -u src/external/mit/lua/dist/src/lstring.h:1.8 src/external/mit/lua/dist/src/lstring.h:1.9
--- src/external/mit/lua/dist/src/lstring.h:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lstring.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lstring.h,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lstring.h,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/ltablib.c
diff -u src/external/mit/lua/dist/src/ltablib.c:1.8 src/external/mit/lua/dist/src/ltablib.c:1.9
--- src/external/mit/lua/dist/src/ltablib.c:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/ltablib.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: ltablib.c,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: ltablib.c,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/ltm.c
diff -u src/external/mit/lua/dist/src/ltm.c:1.8 src/external/mit/lua/dist/src/ltm.c:1.9
--- src/external/mit/lua/dist/src/ltm.c:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/ltm.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: ltm.c,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: ltm.c,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lua.c
diff -u src/external/mit/lua/dist/src/lua.c:1.8 src/external/mit/lua/dist/src/lua.c:1.9
--- src/external/mit/lua/dist/src/lua.c:1.8	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lua.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lua.c,v 1.8 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lua.c,v 1.9 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
@@ -140,7 +140,7 @@ static void print_usage (const char *bad
   "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"

Index: src/external/mit/lua/dist/src/lauxlib.h
diff -u src/external/mit/lua/dist/src/lauxlib.h:1.7 src/external/mit/lua/dist/src/lauxlib.h:1.8
--- src/external/mit/lua/dist/src/lauxlib.h:1.7	Wed Apr 26 13:09:12 2017
+++ src/external/mit/lua/dist/src/lauxlib.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lauxlib.h,v 1.7 2017/04/26 13:09:12 mbalmer Exp $	*/
+/*	$NetBSD: lauxlib.h,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lcode.h
diff -u src/external/mit/lua/dist/src/lcode.h:1.7 src/external/mit/lua/dist/src/lcode.h:1.8
--- src/external/mit/lua/dist/src/lcode.h:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lcode.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lcode.h,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lcode.h,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lfunc.c
diff -u src/external/mit/lua/dist/src/lfunc.c:1.7 src/external/mit/lua/dist/src/lfunc.c:1.8
--- src/external/mit/lua/dist/src/lfunc.c:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lfunc.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lfunc.c,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lfunc.c,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lfunc.h
diff -u src/external/mit/lua/dist/src/lfunc.h:1.7 src/external/mit/lua/dist/src/lfunc.h:1.8
--- src/external/mit/lua/dist/src/lfunc.h:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lfunc.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lfunc.h,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lfunc.h,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lgc.h
diff -u src/external/mit/lua/dist/src/lgc.h:1.7 src/external/mit/lua/dist/src/lgc.h:1.8
--- src/external/mit/lua/dist/src/lgc.h:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lgc.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lgc.h,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lgc.h,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/llex.h
diff -u src/external/mit/lua/dist/src/llex.h:1.7 src/external/mit/lua/dist/src/llex.h:1.8
--- src/external/mit/lua/dist/src/llex.h:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/llex.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: llex.h,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: llex.h,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lmem.h
diff -u src/external/mit/lua/dist/src/lmem.h:1.7 src/external/mit/lua/dist/src/lmem.h:1.8
--- src/external/mit/lua/dist/src/lmem.h:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lmem.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lmem.h,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lmem.h,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lopcodes.c
diff -u src/external/mit/lua/dist/src/lopcodes.c:1.7 src/external/mit/lua/dist/src/lopcodes.c:1.8
--- src/external/mit/lua/dist/src/lopcodes.c:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lopcodes.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lopcodes.c,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lopcodes.c,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lopcodes.h
diff -u src/external/mit/lua/dist/src/lopcodes.h:1.7 src/external/mit/lua/dist/src/lopcodes.h:1.8
--- src/external/mit/lua/dist/src/lopcodes.h:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lopcodes.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lopcodes.h,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lopcodes.h,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lparser.h
diff -u src/external/mit/lua/dist/src/lparser.h:1.7 src/external/mit/lua/dist/src/lparser.h:1.8
--- src/external/mit/lua/dist/src/lparser.h:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lparser.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lparser.h,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lparser.h,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/ltable.h
diff -u src/external/mit/lua/dist/src/ltable.h:1.7 src/external/mit/lua/dist/src/ltable.h:1.8
--- src/external/mit/lua/dist/src/ltable.h:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/ltable.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: ltable.h,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: ltable.h,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
@@ -56,7 +56,7 @@ LUAI_FUNC void luaH_resize (lua_State *L
 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)
Index: src/external/mit/lua/dist/src/ltm.h
diff -u src/external/mit/lua/dist/src/ltm.h:1.7 src/external/mit/lua/dist/src/ltm.h:1.8
--- src/external/mit/lua/dist/src/ltm.h:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/ltm.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: ltm.h,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: ltm.h,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lundump.c
diff -u src/external/mit/lua/dist/src/lundump.c:1.7 src/external/mit/lua/dist/src/lundump.c:1.8
--- src/external/mit/lua/dist/src/lundump.c:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lundump.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lundump.c,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lundump.c,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lutf8lib.c
diff -u src/external/mit/lua/dist/src/lutf8lib.c:1.7 src/external/mit/lua/dist/src/lutf8lib.c:1.8
--- src/external/mit/lua/dist/src/lutf8lib.c:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lutf8lib.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lutf8lib.c,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lutf8lib.c,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
@@ -175,7 +175,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 */
Index: src/external/mit/lua/dist/src/lzio.c
diff -u src/external/mit/lua/dist/src/lzio.c:1.7 src/external/mit/lua/dist/src/lzio.c:1.8
--- src/external/mit/lua/dist/src/lzio.c:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lzio.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lzio.c,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lzio.c,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lzio.h
diff -u src/external/mit/lua/dist/src/lzio.h:1.7 src/external/mit/lua/dist/src/lzio.h:1.8
--- src/external/mit/lua/dist/src/lzio.h:1.7	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lzio.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lzio.h,v 1.7 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lzio.h,v 1.8 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */

Index: src/external/mit/lua/dist/src/lbaselib.c
diff -u src/external/mit/lua/dist/src/lbaselib.c:1.9 src/external/mit/lua/dist/src/lbaselib.c:1.10
--- src/external/mit/lua/dist/src/lbaselib.c:1.9	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lbaselib.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lbaselib.c,v 1.9 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lbaselib.c,v 1.10 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lgc.c
diff -u src/external/mit/lua/dist/src/lgc.c:1.9 src/external/mit/lua/dist/src/lgc.c:1.10
--- src/external/mit/lua/dist/src/lgc.c:1.9	Thu Sep  7 12:52:29 2017
+++ src/external/mit/lua/dist/src/lgc.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lgc.c,v 1.9 2017/09/07 12:52:29 mbalmer Exp $	*/
+/*	$NetBSD: lgc.c,v 1.10 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/llimits.h
diff -u src/external/mit/lua/dist/src/llimits.h:1.9 src/external/mit/lua/dist/src/llimits.h:1.10
--- src/external/mit/lua/dist/src/llimits.h:1.9	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/llimits.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: llimits.h,v 1.9 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: llimits.h,v 1.10 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lobject.h
diff -u src/external/mit/lua/dist/src/lobject.h:1.9 src/external/mit/lua/dist/src/lobject.h:1.10
--- src/external/mit/lua/dist/src/lobject.h:1.9	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lobject.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lobject.h,v 1.9 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lobject.h,v 1.10 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/luac.c
diff -u src/external/mit/lua/dist/src/luac.c:1.9 src/external/mit/lua/dist/src/luac.c:1.10
--- src/external/mit/lua/dist/src/luac.c:1.9	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/luac.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: luac.c,v 1.9 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: luac.c,v 1.10 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
@@ -208,7 +208,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
 */
@@ -354,6 +354,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:
Index: src/external/mit/lua/dist/src/lvm.h
diff -u src/external/mit/lua/dist/src/lvm.h:1.9 src/external/mit/lua/dist/src/lvm.h:1.10
--- src/external/mit/lua/dist/src/lvm.h:1.9	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lvm.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lvm.h,v 1.9 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lvm.h,v 1.10 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */

Index: src/external/mit/lua/dist/src/lbitlib.c
diff -u src/external/mit/lua/dist/src/lbitlib.c:1.6 src/external/mit/lua/dist/src/lbitlib.c:1.7
--- src/external/mit/lua/dist/src/lbitlib.c:1.6	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lbitlib.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lbitlib.c,v 1.6 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lbitlib.c,v 1.7 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lcorolib.c
diff -u src/external/mit/lua/dist/src/lcorolib.c:1.6 src/external/mit/lua/dist/src/lcorolib.c:1.7
--- src/external/mit/lua/dist/src/lcorolib.c:1.6	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lcorolib.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lcorolib.c,v 1.6 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lcorolib.c,v 1.7 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lctype.c
diff -u src/external/mit/lua/dist/src/lctype.c:1.6 src/external/mit/lua/dist/src/lctype.c:1.7
--- src/external/mit/lua/dist/src/lctype.c:1.6	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lctype.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lctype.c,v 1.6 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lctype.c,v 1.7 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lctype.h
diff -u src/external/mit/lua/dist/src/lctype.h:1.6 src/external/mit/lua/dist/src/lctype.h:1.7
--- src/external/mit/lua/dist/src/lctype.h:1.6	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lctype.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lctype.h,v 1.6 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lctype.h,v 1.7 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lprefix.h
diff -u src/external/mit/lua/dist/src/lprefix.h:1.6 src/external/mit/lua/dist/src/lprefix.h:1.7
--- src/external/mit/lua/dist/src/lprefix.h:1.6	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lprefix.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lprefix.h,v 1.6 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lprefix.h,v 1.7 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lualib.h
diff -u src/external/mit/lua/dist/src/lualib.h:1.6 src/external/mit/lua/dist/src/lualib.h:1.7
--- src/external/mit/lua/dist/src/lualib.h:1.6	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lualib.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lualib.h,v 1.6 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lualib.h,v 1.7 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lundump.h
diff -u src/external/mit/lua/dist/src/lundump.h:1.6 src/external/mit/lua/dist/src/lundump.h:1.7
--- src/external/mit/lua/dist/src/lundump.h:1.6	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lundump.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lundump.h,v 1.6 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lundump.h,v 1.7 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */

Index: src/external/mit/lua/dist/src/llex.c
diff -u src/external/mit/lua/dist/src/llex.c:1.11 src/external/mit/lua/dist/src/llex.c:1.12
--- src/external/mit/lua/dist/src/llex.c:1.11	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/llex.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: llex.c,v 1.11 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: llex.c,v 1.12 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
Index: src/external/mit/lua/dist/src/lobject.c
diff -u src/external/mit/lua/dist/src/lobject.c:1.11 src/external/mit/lua/dist/src/lobject.c:1.12
--- src/external/mit/lua/dist/src/lobject.c:1.11	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lobject.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lobject.c,v 1.11 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lobject.c,v 1.12 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
@@ -466,7 +466,8 @@ const char *luaO_pushvfstring (lua_State
       }
       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;
       }

Index: src/external/mit/lua/dist/src/lstrlib.c
diff -u src/external/mit/lua/dist/src/lstrlib.c:1.17 src/external/mit/lua/dist/src/lstrlib.c:1.18
--- src/external/mit/lua/dist/src/lstrlib.c:1.17	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lstrlib.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lstrlib.c,v 1.17 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lstrlib.c,v 1.18 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
@@ -883,7 +883,7 @@ static int lua_number2strx (lua_State *L
       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;
 }
 
@@ -1217,8 +1217,8 @@ static int getnum (const char **fmt, int
 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;
 }
 

Index: src/external/mit/lua/dist/src/luaconf.h
diff -u src/external/mit/lua/dist/src/luaconf.h:1.22 src/external/mit/lua/dist/src/luaconf.h:1.23
--- src/external/mit/lua/dist/src/luaconf.h:1.22	Sat May 26 20:17:56 2018
+++ src/external/mit/lua/dist/src/luaconf.h	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: luaconf.h,v 1.22 2018/05/26 20:17:56 alnsn Exp $	*/
+/*	$NetBSD: luaconf.h,v 1.23 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */
@@ -630,6 +630,13 @@
 
 
 /*
+@@ 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.
 ** Otherwise, you can leave 'lua_number2strx' undefined and Lua will

Index: src/external/mit/lua/dist/src/lvm.c
diff -u src/external/mit/lua/dist/src/lvm.c:1.13 src/external/mit/lua/dist/src/lvm.c:1.14
--- src/external/mit/lua/dist/src/lvm.c:1.13	Wed Apr 26 13:17:33 2017
+++ src/external/mit/lua/dist/src/lvm.c	Sat Aug  4 17:30:01 2018
@@ -1,7 +1,7 @@
-/*	$NetBSD: lvm.c,v 1.13 2017/04/26 13:17:33 mbalmer Exp $	*/
+/*	$NetBSD: lvm.c,v 1.14 2018/08/04 17:30:01 alnsn Exp $	*/
 
 /*
-** 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
 */

Reply via email to