Add stage 06: Lua bootstrap
The goal of stage 06 is to try parse zig synax in lua. I pulled in lpeglable 1.2.0 and parser-gen off github to get started. All of this needs to be cleaned up rather soon. Lua boostraps using tcc and musl from the previous stage. Since musl 0.6.0 doesn't support dynamic linking this build of lua doesn't support shared libraries. I couldn't easily patch musl with dlopen and friends so instead I link statically and call deps with c api.
This commit is contained in:
parent
2ae045cf8a
commit
e6b88d5a0f
170 changed files with 72518 additions and 2 deletions
678
06/lua-5.4.6/doc/contents.html
Normal file
678
06/lua-5.4.6/doc/contents.html
Normal file
|
@ -0,0 +1,678 @@
|
|||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>Lua 5.4 Reference Manual - contents</TITLE>
|
||||
<LINK REL="stylesheet" TYPE="text/css" HREF="lua.css">
|
||||
<LINK REL="stylesheet" TYPE="text/css" HREF="index.css">
|
||||
<META HTTP-EQUIV="content-type" CONTENT="text/html; charset=iso-8859-1">
|
||||
</HEAD>
|
||||
|
||||
<BODY>
|
||||
|
||||
<H1>
|
||||
<A HREF="http://www.lua.org/"><IMG SRC="logo.gif" ALT="Lua"></A>
|
||||
Lua 5.4 Reference Manual
|
||||
</H1>
|
||||
|
||||
<P>
|
||||
The reference manual is the official definition of the Lua language.
|
||||
<BR>
|
||||
For a complete introduction to Lua programming, see the book
|
||||
<A HREF="http://www.lua.org/pil/">Programming in Lua</A>.
|
||||
|
||||
<DIV CLASS="menubar">
|
||||
<A HREF="manual.html">start</A>
|
||||
·
|
||||
<A HREF="#contents">contents</A>
|
||||
·
|
||||
<A HREF="#index">index</A>
|
||||
·
|
||||
<A HREF="http://www.lua.org/manual/">other versions</A>
|
||||
</DIV>
|
||||
|
||||
<P>
|
||||
<SMALL>
|
||||
Copyright © 2020–2023 Lua.org, PUC-Rio.
|
||||
Freely available under the terms of the
|
||||
<A HREF="http://www.lua.org/license.html">Lua license</A>.
|
||||
</SMALL>
|
||||
|
||||
<H2><A NAME="contents">Contents</A></H2>
|
||||
<UL CLASS="contents menubar">
|
||||
<LI><A HREF="manual.html">1 – Introduction</A>
|
||||
<P>
|
||||
<LI><A HREF="manual.html#2">2 – Basic Concepts</A>
|
||||
<UL>
|
||||
<LI><A HREF="manual.html#2.1">2.1 – Values and Types</A>
|
||||
<LI><A HREF="manual.html#2.2">2.2 – Environments and the Global Environment</A>
|
||||
<LI><A HREF="manual.html#2.3">2.3 – Error Handling</A>
|
||||
<LI><A HREF="manual.html#2.4">2.4 – Metatables and Metamethods</A>
|
||||
<LI><A HREF="manual.html#2.5">2.5 – Garbage Collection</A>
|
||||
<UL>
|
||||
<LI><A HREF="manual.html#2.5.1">2.5.1 – Incremental Garbage Collection</A>
|
||||
<LI><A HREF="manual.html#2.5.2">2.5.2 – Generational Garbage Collection</A>
|
||||
<LI><A HREF="manual.html#2.5.3">2.5.3 – Garbage-Collection Metamethods</A>
|
||||
<LI><A HREF="manual.html#2.5.4">2.5.4 – Weak Tables</A>
|
||||
</UL>
|
||||
<LI><A HREF="manual.html#2.6">2.6 – Coroutines</A>
|
||||
</UL>
|
||||
<P>
|
||||
<LI><A HREF="manual.html#3">3 – The Language</A>
|
||||
<UL>
|
||||
<LI><A HREF="manual.html#3.1">3.1 – Lexical Conventions</A>
|
||||
<LI><A HREF="manual.html#3.2">3.2 – Variables</A>
|
||||
<LI><A HREF="manual.html#3.3">3.3 – Statements</A>
|
||||
<UL>
|
||||
<LI><A HREF="manual.html#3.3.1">3.3.1 – Blocks</A>
|
||||
<LI><A HREF="manual.html#3.3.2">3.3.2 – Chunks</A>
|
||||
<LI><A HREF="manual.html#3.3.3">3.3.3 – Assignment</A>
|
||||
<LI><A HREF="manual.html#3.3.4">3.3.4 – Control Structures</A>
|
||||
<LI><A HREF="manual.html#3.3.5">3.3.5 – For Statement</A>
|
||||
<LI><A HREF="manual.html#3.3.6">3.3.6 – Function Calls as Statements</A>
|
||||
<LI><A HREF="manual.html#3.3.7">3.3.7 – Local Declarations</A>
|
||||
<LI><A HREF="manual.html#3.3.8">3.3.8 – To-be-closed Variables</A>
|
||||
</UL>
|
||||
<LI><A HREF="manual.html#3.4">3.4 – Expressions</A>
|
||||
<UL>
|
||||
<LI><A HREF="manual.html#3.4.1">3.4.1 – Arithmetic Operators</A>
|
||||
<LI><A HREF="manual.html#3.4.2">3.4.2 – Bitwise Operators</A>
|
||||
<LI><A HREF="manual.html#3.4.3">3.4.3 – Coercions and Conversions</A>
|
||||
<LI><A HREF="manual.html#3.4.4">3.4.4 – Relational Operators</A>
|
||||
<LI><A HREF="manual.html#3.4.5">3.4.5 – Logical Operators</A>
|
||||
<LI><A HREF="manual.html#3.4.6">3.4.6 – Concatenation</A>
|
||||
<LI><A HREF="manual.html#3.4.7">3.4.7 – The Length Operator</A>
|
||||
<LI><A HREF="manual.html#3.4.8">3.4.8 – Precedence</A>
|
||||
<LI><A HREF="manual.html#3.4.9">3.4.9 – Table Constructors</A>
|
||||
<LI><A HREF="manual.html#3.4.10">3.4.10 – Function Calls</A>
|
||||
<LI><A HREF="manual.html#3.4.11">3.4.11 – Function Definitions</A>
|
||||
<LI><A HREF="manual.html#3.4.12">3.4.12 – Lists of expressions, multiple results, and adjustment<A>
|
||||
|
||||
</UL>
|
||||
<LI><A HREF="manual.html#3.5">3.5 – Visibility Rules</A>
|
||||
</UL>
|
||||
<P>
|
||||
<LI><A HREF="manual.html#4">4 – The Application Program Interface</A>
|
||||
<UL>
|
||||
<LI><A HREF="manual.html#4.1">4.1 – The Stack</A>
|
||||
<UL>
|
||||
<LI><A HREF="manual.html#4.1.1">4.1.1 – Stack Size</A>
|
||||
<LI><A HREF="manual.html#4.1.2">4.1.2 – Valid and Acceptable Indices</A>
|
||||
<LI><A HREF="manual.html#4.1.3">4.1.3 – Pointers to strings</A>
|
||||
</UL>
|
||||
<LI><A HREF="manual.html#4.2">4.2 – C Closures</A>
|
||||
<LI><A HREF="manual.html#4.3">4.3 – Registry</A>
|
||||
<LI><A HREF="manual.html#4.4">4.4 – Error Handling in C</A>
|
||||
<UL>
|
||||
<LI><A HREF="manual.html#4.4.1">4.4.1 – Status Codes</A>
|
||||
</UL>
|
||||
<LI><A HREF="manual.html#4.5">4.5 – Handling Yields in C</A>
|
||||
<LI><A HREF="manual.html#4.6">4.6 – Functions and Types</A>
|
||||
<LI><A HREF="manual.html#4.7">4.7 – The Debug Interface</A>
|
||||
</UL>
|
||||
<P>
|
||||
<LI><A HREF="manual.html#5">5 – The Auxiliary Library</A>
|
||||
<UL>
|
||||
<LI><A HREF="manual.html#5.1">5.1 – Functions and Types</A>
|
||||
</UL>
|
||||
<P>
|
||||
<LI><A HREF="manual.html#6">6 – The Standard Libraries</A>
|
||||
<UL>
|
||||
<LI><A HREF="manual.html#6.1">6.1 – Basic Functions</A>
|
||||
<LI><A HREF="manual.html#6.2">6.2 – Coroutine Manipulation</A>
|
||||
<LI><A HREF="manual.html#6.3">6.3 – Modules</A>
|
||||
<LI><A HREF="manual.html#6.4">6.4 – String Manipulation</A>
|
||||
<UL>
|
||||
<LI><A HREF="manual.html#6.4.1">6.4.1 – Patterns</A>
|
||||
<LI><A HREF="manual.html#6.4.2">6.4.2 – Format Strings for Pack and Unpack</A>
|
||||
</UL>
|
||||
<LI><A HREF="manual.html#6.5">6.5 – UTF-8 Support</A>
|
||||
<LI><A HREF="manual.html#6.6">6.6 – Table Manipulation</A>
|
||||
<LI><A HREF="manual.html#6.7">6.7 – Mathematical Functions</A>
|
||||
<LI><A HREF="manual.html#6.8">6.8 – Input and Output Facilities</A>
|
||||
<LI><A HREF="manual.html#6.9">6.9 – Operating System Facilities</A>
|
||||
<LI><A HREF="manual.html#6.10">6.10 – The Debug Library</A>
|
||||
</UL>
|
||||
<P>
|
||||
<LI><A HREF="manual.html#7">7 – Lua Standalone</A>
|
||||
<P>
|
||||
<LI><A HREF="manual.html#8">8 – Incompatibilities with the Previous Version</A>
|
||||
<UL>
|
||||
<LI><A HREF="manual.html#8.1">8.1 – Incompatibilities in the Language</A>
|
||||
<LI><A HREF="manual.html#8.2">8.2 – Incompatibilities in the Libraries</A>
|
||||
<LI><A HREF="manual.html#8.3">8.3 – Incompatibilities in the API</A>
|
||||
</UL>
|
||||
<P>
|
||||
<LI><A HREF="manual.html#9">9 – The Complete Syntax of Lua</A>
|
||||
</UL>
|
||||
|
||||
<H2><A NAME="index">Index</A></H2>
|
||||
<TABLE CLASS="menubar" WIDTH="100%">
|
||||
<TR>
|
||||
<TD>
|
||||
<H3><A NAME="functions">Lua functions</A></H3>
|
||||
<P>
|
||||
<A HREF="manual.html#6.1">basic</A><BR>
|
||||
<A HREF="manual.html#pdf-_G">_G</A><BR>
|
||||
<A HREF="manual.html#pdf-_VERSION">_VERSION</A><BR>
|
||||
<A HREF="manual.html#pdf-assert">assert</A><BR>
|
||||
<A HREF="manual.html#pdf-collectgarbage">collectgarbage</A><BR>
|
||||
<A HREF="manual.html#pdf-dofile">dofile</A><BR>
|
||||
<A HREF="manual.html#pdf-error">error</A><BR>
|
||||
<A HREF="manual.html#pdf-getmetatable">getmetatable</A><BR>
|
||||
<A HREF="manual.html#pdf-ipairs">ipairs</A><BR>
|
||||
<A HREF="manual.html#pdf-load">load</A><BR>
|
||||
<A HREF="manual.html#pdf-loadfile">loadfile</A><BR>
|
||||
<A HREF="manual.html#pdf-next">next</A><BR>
|
||||
<A HREF="manual.html#pdf-pairs">pairs</A><BR>
|
||||
<A HREF="manual.html#pdf-pcall">pcall</A><BR>
|
||||
<A HREF="manual.html#pdf-print">print</A><BR>
|
||||
<A HREF="manual.html#pdf-rawequal">rawequal</A><BR>
|
||||
<A HREF="manual.html#pdf-rawget">rawget</A><BR>
|
||||
<A HREF="manual.html#pdf-rawlen">rawlen</A><BR>
|
||||
<A HREF="manual.html#pdf-rawset">rawset</A><BR>
|
||||
<A HREF="manual.html#pdf-require">require</A><BR>
|
||||
<A HREF="manual.html#pdf-select">select</A><BR>
|
||||
<A HREF="manual.html#pdf-setmetatable">setmetatable</A><BR>
|
||||
<A HREF="manual.html#pdf-tonumber">tonumber</A><BR>
|
||||
<A HREF="manual.html#pdf-tostring">tostring</A><BR>
|
||||
<A HREF="manual.html#pdf-type">type</A><BR>
|
||||
<A HREF="manual.html#pdf-warn">warn</A><BR>
|
||||
<A HREF="manual.html#pdf-xpcall">xpcall</A><BR>
|
||||
|
||||
<P>
|
||||
<A HREF="manual.html#6.2">coroutine</A><BR>
|
||||
<A HREF="manual.html#pdf-coroutine.close">coroutine.close</A><BR>
|
||||
<A HREF="manual.html#pdf-coroutine.create">coroutine.create</A><BR>
|
||||
<A HREF="manual.html#pdf-coroutine.isyieldable">coroutine.isyieldable</A><BR>
|
||||
<A HREF="manual.html#pdf-coroutine.resume">coroutine.resume</A><BR>
|
||||
<A HREF="manual.html#pdf-coroutine.running">coroutine.running</A><BR>
|
||||
<A HREF="manual.html#pdf-coroutine.status">coroutine.status</A><BR>
|
||||
<A HREF="manual.html#pdf-coroutine.wrap">coroutine.wrap</A><BR>
|
||||
<A HREF="manual.html#pdf-coroutine.yield">coroutine.yield</A><BR>
|
||||
|
||||
<P>
|
||||
<A HREF="manual.html#6.10">debug</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.debug">debug.debug</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.gethook">debug.gethook</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.getinfo">debug.getinfo</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.getlocal">debug.getlocal</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.getmetatable">debug.getmetatable</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.getregistry">debug.getregistry</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.getupvalue">debug.getupvalue</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.getuservalue">debug.getuservalue</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.sethook">debug.sethook</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.setlocal">debug.setlocal</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.setmetatable">debug.setmetatable</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.setupvalue">debug.setupvalue</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.setuservalue">debug.setuservalue</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.traceback">debug.traceback</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.upvalueid">debug.upvalueid</A><BR>
|
||||
<A HREF="manual.html#pdf-debug.upvaluejoin">debug.upvaluejoin</A><BR>
|
||||
|
||||
<P>
|
||||
<A HREF="manual.html#6.8">io</A><BR>
|
||||
<A HREF="manual.html#pdf-io.close">io.close</A><BR>
|
||||
<A HREF="manual.html#pdf-io.flush">io.flush</A><BR>
|
||||
<A HREF="manual.html#pdf-io.input">io.input</A><BR>
|
||||
<A HREF="manual.html#pdf-io.lines">io.lines</A><BR>
|
||||
<A HREF="manual.html#pdf-io.open">io.open</A><BR>
|
||||
<A HREF="manual.html#pdf-io.output">io.output</A><BR>
|
||||
<A HREF="manual.html#pdf-io.popen">io.popen</A><BR>
|
||||
<A HREF="manual.html#pdf-io.read">io.read</A><BR>
|
||||
<A HREF="manual.html#pdf-io.stderr">io.stderr</A><BR>
|
||||
<A HREF="manual.html#pdf-io.stdin">io.stdin</A><BR>
|
||||
<A HREF="manual.html#pdf-io.stdout">io.stdout</A><BR>
|
||||
<A HREF="manual.html#pdf-io.tmpfile">io.tmpfile</A><BR>
|
||||
<A HREF="manual.html#pdf-io.type">io.type</A><BR>
|
||||
<A HREF="manual.html#pdf-io.write">io.write</A><BR>
|
||||
|
||||
<A HREF="manual.html#pdf-file:close">file:close</A><BR>
|
||||
<A HREF="manual.html#pdf-file:flush">file:flush</A><BR>
|
||||
<A HREF="manual.html#pdf-file:lines">file:lines</A><BR>
|
||||
<A HREF="manual.html#pdf-file:read">file:read</A><BR>
|
||||
<A HREF="manual.html#pdf-file:seek">file:seek</A><BR>
|
||||
<A HREF="manual.html#pdf-file:setvbuf">file:setvbuf</A><BR>
|
||||
<A HREF="manual.html#pdf-file:write">file:write</A><BR>
|
||||
|
||||
</TD>
|
||||
<TD>
|
||||
<H3> </H3>
|
||||
<P>
|
||||
<A HREF="manual.html#6.7">math</A><BR>
|
||||
<A HREF="manual.html#pdf-math.abs">math.abs</A><BR>
|
||||
<A HREF="manual.html#pdf-math.acos">math.acos</A><BR>
|
||||
<A HREF="manual.html#pdf-math.asin">math.asin</A><BR>
|
||||
<A HREF="manual.html#pdf-math.atan">math.atan</A><BR>
|
||||
<A HREF="manual.html#pdf-math.ceil">math.ceil</A><BR>
|
||||
<A HREF="manual.html#pdf-math.cos">math.cos</A><BR>
|
||||
<A HREF="manual.html#pdf-math.deg">math.deg</A><BR>
|
||||
<A HREF="manual.html#pdf-math.exp">math.exp</A><BR>
|
||||
<A HREF="manual.html#pdf-math.floor">math.floor</A><BR>
|
||||
<A HREF="manual.html#pdf-math.fmod">math.fmod</A><BR>
|
||||
<A HREF="manual.html#pdf-math.huge">math.huge</A><BR>
|
||||
<A HREF="manual.html#pdf-math.log">math.log</A><BR>
|
||||
<A HREF="manual.html#pdf-math.max">math.max</A><BR>
|
||||
<A HREF="manual.html#pdf-math.maxinteger">math.maxinteger</A><BR>
|
||||
<A HREF="manual.html#pdf-math.min">math.min</A><BR>
|
||||
<A HREF="manual.html#pdf-math.mininteger">math.mininteger</A><BR>
|
||||
<A HREF="manual.html#pdf-math.modf">math.modf</A><BR>
|
||||
<A HREF="manual.html#pdf-math.pi">math.pi</A><BR>
|
||||
<A HREF="manual.html#pdf-math.rad">math.rad</A><BR>
|
||||
<A HREF="manual.html#pdf-math.random">math.random</A><BR>
|
||||
<A HREF="manual.html#pdf-math.randomseed">math.randomseed</A><BR>
|
||||
<A HREF="manual.html#pdf-math.sin">math.sin</A><BR>
|
||||
<A HREF="manual.html#pdf-math.sqrt">math.sqrt</A><BR>
|
||||
<A HREF="manual.html#pdf-math.tan">math.tan</A><BR>
|
||||
<A HREF="manual.html#pdf-math.tointeger">math.tointeger</A><BR>
|
||||
<A HREF="manual.html#pdf-math.type">math.type</A><BR>
|
||||
<A HREF="manual.html#pdf-math.ult">math.ult</A><BR>
|
||||
|
||||
<P>
|
||||
<A HREF="manual.html#6.9">os</A><BR>
|
||||
<A HREF="manual.html#pdf-os.clock">os.clock</A><BR>
|
||||
<A HREF="manual.html#pdf-os.date">os.date</A><BR>
|
||||
<A HREF="manual.html#pdf-os.difftime">os.difftime</A><BR>
|
||||
<A HREF="manual.html#pdf-os.execute">os.execute</A><BR>
|
||||
<A HREF="manual.html#pdf-os.exit">os.exit</A><BR>
|
||||
<A HREF="manual.html#pdf-os.getenv">os.getenv</A><BR>
|
||||
<A HREF="manual.html#pdf-os.remove">os.remove</A><BR>
|
||||
<A HREF="manual.html#pdf-os.rename">os.rename</A><BR>
|
||||
<A HREF="manual.html#pdf-os.setlocale">os.setlocale</A><BR>
|
||||
<A HREF="manual.html#pdf-os.time">os.time</A><BR>
|
||||
<A HREF="manual.html#pdf-os.tmpname">os.tmpname</A><BR>
|
||||
|
||||
<P>
|
||||
<A HREF="manual.html#6.3">package</A><BR>
|
||||
<A HREF="manual.html#pdf-package.config">package.config</A><BR>
|
||||
<A HREF="manual.html#pdf-package.cpath">package.cpath</A><BR>
|
||||
<A HREF="manual.html#pdf-package.loaded">package.loaded</A><BR>
|
||||
<A HREF="manual.html#pdf-package.loadlib">package.loadlib</A><BR>
|
||||
<A HREF="manual.html#pdf-package.path">package.path</A><BR>
|
||||
<A HREF="manual.html#pdf-package.preload">package.preload</A><BR>
|
||||
<A HREF="manual.html#pdf-package.searchers">package.searchers</A><BR>
|
||||
<A HREF="manual.html#pdf-package.searchpath">package.searchpath</A><BR>
|
||||
|
||||
<P>
|
||||
<A HREF="manual.html#6.4">string</A><BR>
|
||||
<A HREF="manual.html#pdf-string.byte">string.byte</A><BR>
|
||||
<A HREF="manual.html#pdf-string.char">string.char</A><BR>
|
||||
<A HREF="manual.html#pdf-string.dump">string.dump</A><BR>
|
||||
<A HREF="manual.html#pdf-string.find">string.find</A><BR>
|
||||
<A HREF="manual.html#pdf-string.format">string.format</A><BR>
|
||||
<A HREF="manual.html#pdf-string.gmatch">string.gmatch</A><BR>
|
||||
<A HREF="manual.html#pdf-string.gsub">string.gsub</A><BR>
|
||||
<A HREF="manual.html#pdf-string.len">string.len</A><BR>
|
||||
<A HREF="manual.html#pdf-string.lower">string.lower</A><BR>
|
||||
<A HREF="manual.html#pdf-string.match">string.match</A><BR>
|
||||
<A HREF="manual.html#pdf-string.pack">string.pack</A><BR>
|
||||
<A HREF="manual.html#pdf-string.packsize">string.packsize</A><BR>
|
||||
<A HREF="manual.html#pdf-string.rep">string.rep</A><BR>
|
||||
<A HREF="manual.html#pdf-string.reverse">string.reverse</A><BR>
|
||||
<A HREF="manual.html#pdf-string.sub">string.sub</A><BR>
|
||||
<A HREF="manual.html#pdf-string.unpack">string.unpack</A><BR>
|
||||
<A HREF="manual.html#pdf-string.upper">string.upper</A><BR>
|
||||
|
||||
<P>
|
||||
<A HREF="manual.html#6.6">table</A><BR>
|
||||
<A HREF="manual.html#pdf-table.concat">table.concat</A><BR>
|
||||
<A HREF="manual.html#pdf-table.insert">table.insert</A><BR>
|
||||
<A HREF="manual.html#pdf-table.move">table.move</A><BR>
|
||||
<A HREF="manual.html#pdf-table.pack">table.pack</A><BR>
|
||||
<A HREF="manual.html#pdf-table.remove">table.remove</A><BR>
|
||||
<A HREF="manual.html#pdf-table.sort">table.sort</A><BR>
|
||||
<A HREF="manual.html#pdf-table.unpack">table.unpack</A><BR>
|
||||
|
||||
<P>
|
||||
<A HREF="manual.html#6.5">utf8</A><BR>
|
||||
<A HREF="manual.html#pdf-utf8.char">utf8.char</A><BR>
|
||||
<A HREF="manual.html#pdf-utf8.charpattern">utf8.charpattern</A><BR>
|
||||
<A HREF="manual.html#pdf-utf8.codepoint">utf8.codepoint</A><BR>
|
||||
<A HREF="manual.html#pdf-utf8.codes">utf8.codes</A><BR>
|
||||
<A HREF="manual.html#pdf-utf8.len">utf8.len</A><BR>
|
||||
<A HREF="manual.html#pdf-utf8.offset">utf8.offset</A><BR>
|
||||
|
||||
<H3><A NAME="metamethods">metamethods</A></H3>
|
||||
<P>
|
||||
<A HREF="manual.html#2.4">__add</A><BR>
|
||||
<A HREF="manual.html#2.4">__band</A><BR>
|
||||
<A HREF="manual.html#2.4">__bnot</A><BR>
|
||||
<A HREF="manual.html#2.4">__bor</A><BR>
|
||||
<A HREF="manual.html#2.4">__bxor</A><BR>
|
||||
<A HREF="manual.html#2.4">__call</A><BR>
|
||||
<A HREF="manual.html#3.3.8">__close</A><BR>
|
||||
<A HREF="manual.html#2.4">__concat</A><BR>
|
||||
<A HREF="manual.html#2.4">__div</A><BR>
|
||||
<A HREF="manual.html#2.4">__eq</A><BR>
|
||||
<A HREF="manual.html#2.5.3">__gc</A><BR>
|
||||
<A HREF="manual.html#2.4">__idiv</A><BR>
|
||||
<A HREF="manual.html#2.4">__index</A><BR>
|
||||
<A HREF="manual.html#2.4">__le</A><BR>
|
||||
<A HREF="manual.html#2.4">__len</A><BR>
|
||||
<A HREF="manual.html#2.4">__lt</A><BR>
|
||||
<A HREF="manual.html#pdf-getmetatable">__metatable</A><BR>
|
||||
<A HREF="manual.html#2.4">__mod</A><BR>
|
||||
<A HREF="manual.html#2.5.4">__mode</A><BR>
|
||||
<A HREF="manual.html#2.4">__mul</A><BR>
|
||||
<A HREF="manual.html#luaL_newmetatable">__name</A><BR>
|
||||
<A HREF="manual.html#2.4">__newindex</A><BR>
|
||||
<A HREF="manual.html#pdf-pairs">__pairs</A><BR>
|
||||
<A HREF="manual.html#2.4">__pow</A><BR>
|
||||
<A HREF="manual.html#2.4">__shl</A><BR>
|
||||
<A HREF="manual.html#2.4">__shr</A><BR>
|
||||
<A HREF="manual.html#2.4">__sub</A><BR>
|
||||
<A HREF="manual.html#pdf-tostring">__tostring</A><BR>
|
||||
<A HREF="manual.html#2.4">__unm</A><BR>
|
||||
|
||||
<H3><A NAME="env">environment<BR>variables</A></H3>
|
||||
<P>
|
||||
<A HREF="manual.html#pdf-LUA_CPATH">LUA_CPATH</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_CPATH_5_4">LUA_CPATH_5_4</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_INIT">LUA_INIT</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_INIT_5_4">LUA_INIT_5_4</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_PATH">LUA_PATH</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_PATH_5_4">LUA_PATH_5_4</A><BR>
|
||||
|
||||
</TD>
|
||||
<TD>
|
||||
<H3><A NAME="api">C API</A></H3>
|
||||
<P>
|
||||
<A HREF="manual.html#lua_Alloc">lua_Alloc</A><BR>
|
||||
<A HREF="manual.html#lua_CFunction">lua_CFunction</A><BR>
|
||||
<A HREF="manual.html#lua_Debug">lua_Debug</A><BR>
|
||||
<A HREF="manual.html#lua_Hook">lua_Hook</A><BR>
|
||||
<A HREF="manual.html#lua_Integer">lua_Integer</A><BR>
|
||||
<A HREF="manual.html#lua_KContext">lua_KContext</A><BR>
|
||||
<A HREF="manual.html#lua_KFunction">lua_KFunction</A><BR>
|
||||
<A HREF="manual.html#lua_Number">lua_Number</A><BR>
|
||||
<A HREF="manual.html#lua_Reader">lua_Reader</A><BR>
|
||||
<A HREF="manual.html#lua_State">lua_State</A><BR>
|
||||
<A HREF="manual.html#lua_Unsigned">lua_Unsigned</A><BR>
|
||||
<A HREF="manual.html#lua_WarnFunction">lua_WarnFunction</A><BR>
|
||||
<A HREF="manual.html#lua_Writer">lua_Writer</A><BR>
|
||||
|
||||
<P>
|
||||
<A HREF="manual.html#lua_absindex">lua_absindex</A><BR>
|
||||
<A HREF="manual.html#lua_arith">lua_arith</A><BR>
|
||||
<A HREF="manual.html#lua_atpanic">lua_atpanic</A><BR>
|
||||
<A HREF="manual.html#lua_call">lua_call</A><BR>
|
||||
<A HREF="manual.html#lua_callk">lua_callk</A><BR>
|
||||
<A HREF="manual.html#lua_checkstack">lua_checkstack</A><BR>
|
||||
<A HREF="manual.html#lua_close">lua_close</A><BR>
|
||||
<A HREF="manual.html#lua_closeslot">lua_closeslot</A><BR>
|
||||
<A HREF="manual.html#lua_compare">lua_compare</A><BR>
|
||||
<A HREF="manual.html#lua_concat">lua_concat</A><BR>
|
||||
<A HREF="manual.html#lua_copy">lua_copy</A><BR>
|
||||
<A HREF="manual.html#lua_createtable">lua_createtable</A><BR>
|
||||
<A HREF="manual.html#lua_dump">lua_dump</A><BR>
|
||||
<A HREF="manual.html#lua_error">lua_error</A><BR>
|
||||
<A HREF="manual.html#lua_gc">lua_gc</A><BR>
|
||||
<A HREF="manual.html#lua_getallocf">lua_getallocf</A><BR>
|
||||
<A HREF="manual.html#lua_getextraspace">lua_getextraspace</A><BR>
|
||||
<A HREF="manual.html#lua_getfield">lua_getfield</A><BR>
|
||||
<A HREF="manual.html#lua_getglobal">lua_getglobal</A><BR>
|
||||
<A HREF="manual.html#lua_gethook">lua_gethook</A><BR>
|
||||
<A HREF="manual.html#lua_gethookcount">lua_gethookcount</A><BR>
|
||||
<A HREF="manual.html#lua_gethookmask">lua_gethookmask</A><BR>
|
||||
<A HREF="manual.html#lua_geti">lua_geti</A><BR>
|
||||
<A HREF="manual.html#lua_getinfo">lua_getinfo</A><BR>
|
||||
<A HREF="manual.html#lua_getiuservalue">lua_getiuservalue</A><BR>
|
||||
<A HREF="manual.html#lua_getlocal">lua_getlocal</A><BR>
|
||||
<A HREF="manual.html#lua_getmetatable">lua_getmetatable</A><BR>
|
||||
<A HREF="manual.html#lua_getstack">lua_getstack</A><BR>
|
||||
<A HREF="manual.html#lua_gettable">lua_gettable</A><BR>
|
||||
<A HREF="manual.html#lua_gettop">lua_gettop</A><BR>
|
||||
<A HREF="manual.html#lua_getupvalue">lua_getupvalue</A><BR>
|
||||
<A HREF="manual.html#lua_insert">lua_insert</A><BR>
|
||||
<A HREF="manual.html#lua_isboolean">lua_isboolean</A><BR>
|
||||
<A HREF="manual.html#lua_iscfunction">lua_iscfunction</A><BR>
|
||||
<A HREF="manual.html#lua_isfunction">lua_isfunction</A><BR>
|
||||
<A HREF="manual.html#lua_isinteger">lua_isinteger</A><BR>
|
||||
<A HREF="manual.html#lua_islightuserdata">lua_islightuserdata</A><BR>
|
||||
<A HREF="manual.html#lua_isnil">lua_isnil</A><BR>
|
||||
<A HREF="manual.html#lua_isnone">lua_isnone</A><BR>
|
||||
<A HREF="manual.html#lua_isnoneornil">lua_isnoneornil</A><BR>
|
||||
<A HREF="manual.html#lua_isnumber">lua_isnumber</A><BR>
|
||||
<A HREF="manual.html#lua_isstring">lua_isstring</A><BR>
|
||||
<A HREF="manual.html#lua_istable">lua_istable</A><BR>
|
||||
<A HREF="manual.html#lua_isthread">lua_isthread</A><BR>
|
||||
<A HREF="manual.html#lua_isuserdata">lua_isuserdata</A><BR>
|
||||
<A HREF="manual.html#lua_isyieldable">lua_isyieldable</A><BR>
|
||||
<A HREF="manual.html#lua_len">lua_len</A><BR>
|
||||
<A HREF="manual.html#lua_load">lua_load</A><BR>
|
||||
<A HREF="manual.html#lua_newstate">lua_newstate</A><BR>
|
||||
<A HREF="manual.html#lua_newtable">lua_newtable</A><BR>
|
||||
<A HREF="manual.html#lua_newthread">lua_newthread</A><BR>
|
||||
<A HREF="manual.html#lua_newuserdatauv">lua_newuserdatauv</A><BR>
|
||||
<A HREF="manual.html#lua_next">lua_next</A><BR>
|
||||
<A HREF="manual.html#lua_numbertointeger">lua_numbertointeger</A><BR>
|
||||
<A HREF="manual.html#lua_pcall">lua_pcall</A><BR>
|
||||
<A HREF="manual.html#lua_pcallk">lua_pcallk</A><BR>
|
||||
<A HREF="manual.html#lua_pop">lua_pop</A><BR>
|
||||
<A HREF="manual.html#lua_pushboolean">lua_pushboolean</A><BR>
|
||||
<A HREF="manual.html#lua_pushcclosure">lua_pushcclosure</A><BR>
|
||||
<A HREF="manual.html#lua_pushcfunction">lua_pushcfunction</A><BR>
|
||||
<A HREF="manual.html#lua_pushfstring">lua_pushfstring</A><BR>
|
||||
<A HREF="manual.html#lua_pushglobaltable">lua_pushglobaltable</A><BR>
|
||||
<A HREF="manual.html#lua_pushinteger">lua_pushinteger</A><BR>
|
||||
<A HREF="manual.html#lua_pushlightuserdata">lua_pushlightuserdata</A><BR>
|
||||
<A HREF="manual.html#lua_pushliteral">lua_pushliteral</A><BR>
|
||||
<A HREF="manual.html#lua_pushlstring">lua_pushlstring</A><BR>
|
||||
<A HREF="manual.html#lua_pushnil">lua_pushnil</A><BR>
|
||||
<A HREF="manual.html#lua_pushnumber">lua_pushnumber</A><BR>
|
||||
<A HREF="manual.html#lua_pushstring">lua_pushstring</A><BR>
|
||||
<A HREF="manual.html#lua_pushthread">lua_pushthread</A><BR>
|
||||
<A HREF="manual.html#lua_pushvalue">lua_pushvalue</A><BR>
|
||||
<A HREF="manual.html#lua_pushvfstring">lua_pushvfstring</A><BR>
|
||||
<A HREF="manual.html#lua_rawequal">lua_rawequal</A><BR>
|
||||
<A HREF="manual.html#lua_rawget">lua_rawget</A><BR>
|
||||
<A HREF="manual.html#lua_rawgeti">lua_rawgeti</A><BR>
|
||||
<A HREF="manual.html#lua_rawgetp">lua_rawgetp</A><BR>
|
||||
<A HREF="manual.html#lua_rawlen">lua_rawlen</A><BR>
|
||||
<A HREF="manual.html#lua_rawset">lua_rawset</A><BR>
|
||||
<A HREF="manual.html#lua_rawseti">lua_rawseti</A><BR>
|
||||
<A HREF="manual.html#lua_rawsetp">lua_rawsetp</A><BR>
|
||||
<A HREF="manual.html#lua_register">lua_register</A><BR>
|
||||
<A HREF="manual.html#lua_remove">lua_remove</A><BR>
|
||||
<A HREF="manual.html#lua_replace">lua_replace</A><BR>
|
||||
<A HREF="manual.html#lua_resetthread">lua_resetthread</A><BR>
|
||||
<A HREF="manual.html#lua_resume">lua_resume</A><BR>
|
||||
<A HREF="manual.html#lua_rotate">lua_rotate</A><BR>
|
||||
<A HREF="manual.html#lua_setallocf">lua_setallocf</A><BR>
|
||||
<A HREF="manual.html#lua_setfield">lua_setfield</A><BR>
|
||||
<A HREF="manual.html#lua_setglobal">lua_setglobal</A><BR>
|
||||
<A HREF="manual.html#lua_sethook">lua_sethook</A><BR>
|
||||
<A HREF="manual.html#lua_seti">lua_seti</A><BR>
|
||||
<A HREF="manual.html#lua_setiuservalue">lua_setiuservalue</A><BR>
|
||||
<A HREF="manual.html#lua_setlocal">lua_setlocal</A><BR>
|
||||
<A HREF="manual.html#lua_setmetatable">lua_setmetatable</A><BR>
|
||||
<A HREF="manual.html#lua_settable">lua_settable</A><BR>
|
||||
<A HREF="manual.html#lua_settop">lua_settop</A><BR>
|
||||
<A HREF="manual.html#lua_setupvalue">lua_setupvalue</A><BR>
|
||||
<A HREF="manual.html#lua_setwarnf">lua_setwarnf</A><BR>
|
||||
<A HREF="manual.html#lua_status">lua_status</A><BR>
|
||||
<A HREF="manual.html#lua_stringtonumber">lua_stringtonumber</A><BR>
|
||||
<A HREF="manual.html#lua_toboolean">lua_toboolean</A><BR>
|
||||
<A HREF="manual.html#lua_tocfunction">lua_tocfunction</A><BR>
|
||||
<A HREF="manual.html#lua_toclose">lua_toclose</A><BR>
|
||||
<A HREF="manual.html#lua_tointeger">lua_tointeger</A><BR>
|
||||
<A HREF="manual.html#lua_tointegerx">lua_tointegerx</A><BR>
|
||||
<A HREF="manual.html#lua_tolstring">lua_tolstring</A><BR>
|
||||
<A HREF="manual.html#lua_tonumber">lua_tonumber</A><BR>
|
||||
<A HREF="manual.html#lua_tonumberx">lua_tonumberx</A><BR>
|
||||
<A HREF="manual.html#lua_topointer">lua_topointer</A><BR>
|
||||
<A HREF="manual.html#lua_tostring">lua_tostring</A><BR>
|
||||
<A HREF="manual.html#lua_tothread">lua_tothread</A><BR>
|
||||
<A HREF="manual.html#lua_touserdata">lua_touserdata</A><BR>
|
||||
<A HREF="manual.html#lua_type">lua_type</A><BR>
|
||||
<A HREF="manual.html#lua_typename">lua_typename</A><BR>
|
||||
<A HREF="manual.html#lua_upvalueid">lua_upvalueid</A><BR>
|
||||
<A HREF="manual.html#lua_upvalueindex">lua_upvalueindex</A><BR>
|
||||
<A HREF="manual.html#lua_upvaluejoin">lua_upvaluejoin</A><BR>
|
||||
<A HREF="manual.html#lua_version">lua_version</A><BR>
|
||||
<A HREF="manual.html#lua_warning">lua_warning</A><BR>
|
||||
<A HREF="manual.html#lua_xmove">lua_xmove</A><BR>
|
||||
<A HREF="manual.html#lua_yield">lua_yield</A><BR>
|
||||
<A HREF="manual.html#lua_yieldk">lua_yieldk</A><BR>
|
||||
|
||||
</TD>
|
||||
<TD>
|
||||
<H3><A NAME="auxlib">auxiliary library</A></H3>
|
||||
<P>
|
||||
<A HREF="manual.html#luaL_Buffer">luaL_Buffer</A><BR>
|
||||
<A HREF="manual.html#luaL_Reg">luaL_Reg</A><BR>
|
||||
<A HREF="manual.html#luaL_Stream">luaL_Stream</A><BR>
|
||||
|
||||
<P>
|
||||
<A HREF="manual.html#luaL_addchar">luaL_addchar</A><BR>
|
||||
<A HREF="manual.html#luaL_addgsub">luaL_addgsub</A><BR>
|
||||
<A HREF="manual.html#luaL_addlstring">luaL_addlstring</A><BR>
|
||||
<A HREF="manual.html#luaL_addsize">luaL_addsize</A><BR>
|
||||
<A HREF="manual.html#luaL_addstring">luaL_addstring</A><BR>
|
||||
<A HREF="manual.html#luaL_addvalue">luaL_addvalue</A><BR>
|
||||
<A HREF="manual.html#luaL_argcheck">luaL_argcheck</A><BR>
|
||||
<A HREF="manual.html#luaL_argerror">luaL_argerror</A><BR>
|
||||
<A HREF="manual.html#luaL_argexpected">luaL_argexpected</A><BR>
|
||||
<A HREF="manual.html#luaL_buffaddr">luaL_buffaddr</A><BR>
|
||||
<A HREF="manual.html#luaL_buffinit">luaL_buffinit</A><BR>
|
||||
<A HREF="manual.html#luaL_buffinitsize">luaL_buffinitsize</A><BR>
|
||||
<A HREF="manual.html#luaL_bufflen">luaL_bufflen</A><BR>
|
||||
<A HREF="manual.html#luaL_buffsub">luaL_buffsub</A><BR>
|
||||
<A HREF="manual.html#luaL_callmeta">luaL_callmeta</A><BR>
|
||||
<A HREF="manual.html#luaL_checkany">luaL_checkany</A><BR>
|
||||
<A HREF="manual.html#luaL_checkinteger">luaL_checkinteger</A><BR>
|
||||
<A HREF="manual.html#luaL_checklstring">luaL_checklstring</A><BR>
|
||||
<A HREF="manual.html#luaL_checknumber">luaL_checknumber</A><BR>
|
||||
<A HREF="manual.html#luaL_checkoption">luaL_checkoption</A><BR>
|
||||
<A HREF="manual.html#luaL_checkstack">luaL_checkstack</A><BR>
|
||||
<A HREF="manual.html#luaL_checkstring">luaL_checkstring</A><BR>
|
||||
<A HREF="manual.html#luaL_checktype">luaL_checktype</A><BR>
|
||||
<A HREF="manual.html#luaL_checkudata">luaL_checkudata</A><BR>
|
||||
<A HREF="manual.html#luaL_checkversion">luaL_checkversion</A><BR>
|
||||
<A HREF="manual.html#luaL_dofile">luaL_dofile</A><BR>
|
||||
<A HREF="manual.html#luaL_dostring">luaL_dostring</A><BR>
|
||||
<A HREF="manual.html#luaL_error">luaL_error</A><BR>
|
||||
<A HREF="manual.html#luaL_execresult">luaL_execresult</A><BR>
|
||||
<A HREF="manual.html#luaL_fileresult">luaL_fileresult</A><BR>
|
||||
<A HREF="manual.html#luaL_getmetafield">luaL_getmetafield</A><BR>
|
||||
<A HREF="manual.html#luaL_getmetatable">luaL_getmetatable</A><BR>
|
||||
<A HREF="manual.html#luaL_getsubtable">luaL_getsubtable</A><BR>
|
||||
<A HREF="manual.html#luaL_gsub">luaL_gsub</A><BR>
|
||||
<A HREF="manual.html#luaL_len">luaL_len</A><BR>
|
||||
<A HREF="manual.html#luaL_loadbuffer">luaL_loadbuffer</A><BR>
|
||||
<A HREF="manual.html#luaL_loadbufferx">luaL_loadbufferx</A><BR>
|
||||
<A HREF="manual.html#luaL_loadfile">luaL_loadfile</A><BR>
|
||||
<A HREF="manual.html#luaL_loadfilex">luaL_loadfilex</A><BR>
|
||||
<A HREF="manual.html#luaL_loadstring">luaL_loadstring</A><BR>
|
||||
<A HREF="manual.html#luaL_newlib">luaL_newlib</A><BR>
|
||||
<A HREF="manual.html#luaL_newlibtable">luaL_newlibtable</A><BR>
|
||||
<A HREF="manual.html#luaL_newmetatable">luaL_newmetatable</A><BR>
|
||||
<A HREF="manual.html#luaL_newstate">luaL_newstate</A><BR>
|
||||
<A HREF="manual.html#luaL_openlibs">luaL_openlibs</A><BR>
|
||||
<A HREF="manual.html#luaL_opt">luaL_opt</A><BR>
|
||||
<A HREF="manual.html#luaL_optinteger">luaL_optinteger</A><BR>
|
||||
<A HREF="manual.html#luaL_optlstring">luaL_optlstring</A><BR>
|
||||
<A HREF="manual.html#luaL_optnumber">luaL_optnumber</A><BR>
|
||||
<A HREF="manual.html#luaL_optstring">luaL_optstring</A><BR>
|
||||
<A HREF="manual.html#luaL_prepbuffer">luaL_prepbuffer</A><BR>
|
||||
<A HREF="manual.html#luaL_prepbuffsize">luaL_prepbuffsize</A><BR>
|
||||
<A HREF="manual.html#luaL_pushfail">luaL_pushfail</A><BR>
|
||||
<A HREF="manual.html#luaL_pushresult">luaL_pushresult</A><BR>
|
||||
<A HREF="manual.html#luaL_pushresultsize">luaL_pushresultsize</A><BR>
|
||||
<A HREF="manual.html#luaL_ref">luaL_ref</A><BR>
|
||||
<A HREF="manual.html#luaL_requiref">luaL_requiref</A><BR>
|
||||
<A HREF="manual.html#luaL_setfuncs">luaL_setfuncs</A><BR>
|
||||
<A HREF="manual.html#luaL_setmetatable">luaL_setmetatable</A><BR>
|
||||
<A HREF="manual.html#luaL_testudata">luaL_testudata</A><BR>
|
||||
<A HREF="manual.html#luaL_tolstring">luaL_tolstring</A><BR>
|
||||
<A HREF="manual.html#luaL_traceback">luaL_traceback</A><BR>
|
||||
<A HREF="manual.html#luaL_typeerror">luaL_typeerror</A><BR>
|
||||
<A HREF="manual.html#luaL_typename">luaL_typename</A><BR>
|
||||
<A HREF="manual.html#luaL_unref">luaL_unref</A><BR>
|
||||
<A HREF="manual.html#luaL_where">luaL_where</A><BR>
|
||||
|
||||
<H3><A NAME="library">standard library</A></H3>
|
||||
<P>
|
||||
<A HREF="manual.html#pdf-luaopen_base">luaopen_base</A><BR>
|
||||
<A HREF="manual.html#pdf-luaopen_coroutine">luaopen_coroutine</A><BR>
|
||||
<A HREF="manual.html#pdf-luaopen_debug">luaopen_debug</A><BR>
|
||||
<A HREF="manual.html#pdf-luaopen_io">luaopen_io</A><BR>
|
||||
<A HREF="manual.html#pdf-luaopen_math">luaopen_math</A><BR>
|
||||
<A HREF="manual.html#pdf-luaopen_os">luaopen_os</A><BR>
|
||||
<A HREF="manual.html#pdf-luaopen_package">luaopen_package</A><BR>
|
||||
<A HREF="manual.html#pdf-luaopen_string">luaopen_string</A><BR>
|
||||
<A HREF="manual.html#pdf-luaopen_table">luaopen_table</A><BR>
|
||||
<A HREF="manual.html#pdf-luaopen_utf8">luaopen_utf8</A><BR>
|
||||
|
||||
<H3><A NAME="constants">constants</A></H3>
|
||||
<P>
|
||||
<A HREF="manual.html#pdf-LUA_ERRERR">LUA_ERRERR</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_ERRFILE">LUA_ERRFILE</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_ERRMEM">LUA_ERRMEM</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_ERRRUN">LUA_ERRRUN</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_ERRSYNTAX">LUA_ERRSYNTAX</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_HOOKCALL">LUA_HOOKCALL</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_HOOKCOUNT">LUA_HOOKCOUNT</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_HOOKLINE">LUA_HOOKLINE</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_HOOKRET">LUA_HOOKRET</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_HOOKTAILCALL">LUA_HOOKTAILCALL</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_LOADED_TABLE">LUA_LOADED_TABLE</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_MASKCALL">LUA_MASKCALL</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_MASKCOUNT">LUA_MASKCOUNT</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_MASKLINE">LUA_MASKLINE</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_MASKRET">LUA_MASKRET</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_MAXINTEGER">LUA_MAXINTEGER</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_MININTEGER">LUA_MININTEGER</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_MINSTACK">LUA_MINSTACK</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_MULTRET">LUA_MULTRET</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_NOREF">LUA_NOREF</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OK">LUA_OK</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPADD">LUA_OPADD</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPBAND">LUA_OPBAND</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPBNOT">LUA_OPBNOT</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPBOR">LUA_OPBOR</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPBXOR">LUA_OPBXOR</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPDIV">LUA_OPDIV</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPEQ">LUA_OPEQ</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPIDIV">LUA_OPIDIV</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPLE">LUA_OPLE</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPLT">LUA_OPLT</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPMOD">LUA_OPMOD</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPMUL">LUA_OPMUL</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPPOW">LUA_OPPOW</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPSHL">LUA_OPSHL</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPSHR">LUA_OPSHR</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPSUB">LUA_OPSUB</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_OPUNM">LUA_OPUNM</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_PRELOAD_TABLE">LUA_PRELOAD_TABLE</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_REFNIL">LUA_REFNIL</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_REGISTRYINDEX">LUA_REGISTRYINDEX</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_RIDX_GLOBALS">LUA_RIDX_GLOBALS</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_RIDX_MAINTHREAD">LUA_RIDX_MAINTHREAD</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_TBOOLEAN">LUA_TBOOLEAN</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_TFUNCTION">LUA_TFUNCTION</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_TLIGHTUSERDATA">LUA_TLIGHTUSERDATA</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_TNIL">LUA_TNIL</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_TNONE">LUA_TNONE</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_TNUMBER">LUA_TNUMBER</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_TSTRING">LUA_TSTRING</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_TTABLE">LUA_TTABLE</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_TTHREAD">LUA_TTHREAD</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_TUSERDATA">LUA_TUSERDATA</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_USE_APICHECK">LUA_USE_APICHECK</A><BR>
|
||||
<A HREF="manual.html#pdf-LUA_YIELD">LUA_YIELD</A><BR>
|
||||
<A HREF="manual.html#pdf-LUAL_BUFFERSIZE">LUAL_BUFFERSIZE</A><BR>
|
||||
|
||||
</TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
|
||||
<P CLASS="footer">
|
||||
Last update:
|
||||
Sat Apr 1 17:57:05 UTC 2023
|
||||
</P>
|
||||
<!--
|
||||
Last change: revised for Lua 5.4.5
|
||||
-->
|
||||
|
||||
</BODY>
|
||||
</HTML>
|
21
06/lua-5.4.6/doc/index.css
Normal file
21
06/lua-5.4.6/doc/index.css
Normal file
|
@ -0,0 +1,21 @@
|
|||
ul {
|
||||
list-style-type: none ;
|
||||
}
|
||||
|
||||
ul.contents {
|
||||
padding: 0 ;
|
||||
}
|
||||
|
||||
table {
|
||||
border: none ;
|
||||
border-spacing: 0 ;
|
||||
border-collapse: collapse ;
|
||||
}
|
||||
|
||||
td {
|
||||
vertical-align: top ;
|
||||
padding: 0 ;
|
||||
text-align: left ;
|
||||
line-height: 1.25 ;
|
||||
width: 15% ;
|
||||
}
|
BIN
06/lua-5.4.6/doc/logo.gif
Normal file
BIN
06/lua-5.4.6/doc/logo.gif
Normal file
Binary file not shown.
After Width: | Height: | Size: 9.7 KiB |
155
06/lua-5.4.6/doc/lua.1
Normal file
155
06/lua-5.4.6/doc/lua.1
Normal file
|
@ -0,0 +1,155 @@
|
|||
.\" $Id: lua.man,v 1.14 2022/09/23 09:06:36 lhf Exp $
|
||||
.TH LUA 1 "$Date: 2022/09/23 09:06:36 $"
|
||||
.SH NAME
|
||||
lua \- Lua interpreter
|
||||
.SH SYNOPSIS
|
||||
.B lua
|
||||
[
|
||||
.I options
|
||||
]
|
||||
[
|
||||
.I script
|
||||
[
|
||||
.I args
|
||||
]
|
||||
]
|
||||
.SH DESCRIPTION
|
||||
.B lua
|
||||
is the standalone Lua interpreter.
|
||||
It loads and executes Lua programs,
|
||||
either in textual source form or
|
||||
in precompiled binary form.
|
||||
(Precompiled binaries are output by
|
||||
.BR luac ,
|
||||
the Lua compiler.)
|
||||
.B lua
|
||||
can be used as a batch interpreter and also interactively.
|
||||
.LP
|
||||
After handling the
|
||||
.IR options ,
|
||||
the Lua program in file
|
||||
.I script
|
||||
is loaded and executed.
|
||||
The
|
||||
.I args
|
||||
are available to
|
||||
.I script
|
||||
as strings in a global table named
|
||||
.B arg
|
||||
and also as arguments to its main function.
|
||||
When called without arguments,
|
||||
.B lua
|
||||
behaves as
|
||||
.B "lua \-v \-i"
|
||||
if the standard input is a terminal,
|
||||
and as
|
||||
.B "lua \-"
|
||||
otherwise.
|
||||
.LP
|
||||
In interactive mode,
|
||||
.B lua
|
||||
prompts the user,
|
||||
reads lines from the standard input,
|
||||
and executes them as they are read.
|
||||
If the line contains an expression,
|
||||
then the line is evaluated and the result is printed.
|
||||
If a line does not contain a complete statement,
|
||||
then a secondary prompt is displayed and
|
||||
lines are read until a complete statement is formed or
|
||||
a syntax error is found.
|
||||
.LP
|
||||
Before handling command line options and scripts,
|
||||
.B lua
|
||||
checks the contents of the environment variables
|
||||
.B LUA_INIT_5_4
|
||||
and
|
||||
.BR LUA_INIT ,
|
||||
in that order.
|
||||
If the contents are of the form
|
||||
.RI '@ filename ',
|
||||
then
|
||||
.I filename
|
||||
is executed.
|
||||
Otherwise, the contents are assumed to be a Lua statement and is executed.
|
||||
When
|
||||
.B LUA_INIT_5_4
|
||||
is defined,
|
||||
.B LUA_INIT
|
||||
is ignored.
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
.BI \-e " stat"
|
||||
execute statement
|
||||
.IR stat .
|
||||
.TP
|
||||
.B \-i
|
||||
enter interactive mode after executing
|
||||
.IR script .
|
||||
.TP
|
||||
.BI \-l " mod"
|
||||
require library
|
||||
.I mod
|
||||
into global
|
||||
.IR mod .
|
||||
.TP
|
||||
.BI \-l " g=mod"
|
||||
require library
|
||||
.I mod
|
||||
into global
|
||||
.IR g .
|
||||
.TP
|
||||
.B \-v
|
||||
show version information.
|
||||
.TP
|
||||
.B \-E
|
||||
ignore environment variables.
|
||||
.TP
|
||||
.B \-W
|
||||
turn warnings on.
|
||||
.TP
|
||||
.B \-\-
|
||||
stop handling options.
|
||||
.TP
|
||||
.B \-
|
||||
stop handling options and execute the standard input as a file.
|
||||
.SH ENVIRONMENT VARIABLES
|
||||
The following environment variables affect the execution of
|
||||
.BR lua .
|
||||
When defined,
|
||||
the version-specific variants take priority
|
||||
and the version-neutral variants are ignored.
|
||||
.TP
|
||||
.B LUA_INIT, LUA_INIT_5_4
|
||||
Code to be executed before command line options and scripts.
|
||||
.TP
|
||||
.B LUA_PATH, LUA_PATH_5_4
|
||||
Initial value of package.cpath,
|
||||
the path used by require to search for Lua loaders.
|
||||
.TP
|
||||
.B LUA_CPATH, LUA_CPATH_5_4
|
||||
Initial value of package.cpath,
|
||||
the path used by require to search for C loaders.
|
||||
.SH EXIT STATUS
|
||||
If a script calls os.exit,
|
||||
then
|
||||
.B lua
|
||||
exits with the given exit status.
|
||||
Otherwise,
|
||||
.B lua
|
||||
exits
|
||||
with EXIT_SUCCESS (0 on POSIX systems) if there were no errors
|
||||
and
|
||||
with EXIT_FAILURE (1 on POSIX systems) if there were errors.
|
||||
Errors raised in interactive mode do not cause exits.
|
||||
.SH DIAGNOSTICS
|
||||
Error messages should be self explanatory.
|
||||
.SH "SEE ALSO"
|
||||
.BR luac (1)
|
||||
.br
|
||||
The documentation at lua.org,
|
||||
especially section 7 of the reference manual.
|
||||
.SH AUTHORS
|
||||
R. Ierusalimschy,
|
||||
L. H. de Figueiredo,
|
||||
W. Celes
|
||||
.\" EOF
|
161
06/lua-5.4.6/doc/lua.css
Normal file
161
06/lua-5.4.6/doc/lua.css
Normal file
|
@ -0,0 +1,161 @@
|
|||
html {
|
||||
background-color: #F8F8F8 ;
|
||||
}
|
||||
|
||||
body {
|
||||
background-color: #FFFFFF ;
|
||||
color: #000000 ;
|
||||
font-family: Helvetica, Arial, sans-serif ;
|
||||
text-align: justify ;
|
||||
line-height: 1.25 ;
|
||||
margin: 16px auto ;
|
||||
padding: 32px ;
|
||||
border: solid #ccc 1px ;
|
||||
border-radius: 20px ;
|
||||
max-width: 70em ;
|
||||
width: 90% ;
|
||||
}
|
||||
|
||||
h1, h2, h3, h4 {
|
||||
color: #000080 ;
|
||||
font-family: Verdana, Geneva, sans-serif ;
|
||||
font-weight: normal ;
|
||||
font-style: normal ;
|
||||
text-align: left ;
|
||||
}
|
||||
|
||||
h1 {
|
||||
font-size: 28pt ;
|
||||
}
|
||||
|
||||
h1 img {
|
||||
vertical-align: text-bottom ;
|
||||
}
|
||||
|
||||
h2:before {
|
||||
content: "\2756" ;
|
||||
padding-right: 0.5em ;
|
||||
}
|
||||
|
||||
a {
|
||||
text-decoration: none ;
|
||||
}
|
||||
|
||||
a:link {
|
||||
color: #000080 ;
|
||||
}
|
||||
|
||||
a:link:hover, a:visited:hover {
|
||||
background-color: #D0D0FF ;
|
||||
color: #000080 ;
|
||||
border-radius: 4px ;
|
||||
}
|
||||
|
||||
a:link:active, a:visited:active {
|
||||
color: #FF0000 ;
|
||||
}
|
||||
|
||||
div.menubar {
|
||||
padding-bottom: 0.5em ;
|
||||
}
|
||||
|
||||
p.menubar {
|
||||
margin-left: 2.5em ;
|
||||
}
|
||||
|
||||
.menubar a:hover {
|
||||
margin: -3px -3px -3px -3px ;
|
||||
padding: 3px 3px 3px 3px ;
|
||||
border-radius: 4px ;
|
||||
}
|
||||
|
||||
:target {
|
||||
background-color: #F0F0F0 ;
|
||||
margin: -8px ;
|
||||
padding: 8px ;
|
||||
border-radius: 8px ;
|
||||
outline: none ;
|
||||
}
|
||||
|
||||
hr {
|
||||
display: none ;
|
||||
}
|
||||
|
||||
table hr {
|
||||
background-color: #a0a0a0 ;
|
||||
color: #a0a0a0 ;
|
||||
border: 0 ;
|
||||
height: 1px ;
|
||||
display: block ;
|
||||
}
|
||||
|
||||
.footer {
|
||||
color: gray ;
|
||||
font-size: x-small ;
|
||||
text-transform: lowercase ;
|
||||
}
|
||||
|
||||
input[type=text] {
|
||||
border: solid #a0a0a0 2px ;
|
||||
border-radius: 2em ;
|
||||
background-image: url('images/search.png') ;
|
||||
background-repeat: no-repeat ;
|
||||
background-position: 4px center ;
|
||||
padding-left: 20px ;
|
||||
height: 2em ;
|
||||
}
|
||||
|
||||
pre.session {
|
||||
background-color: #F8F8F8 ;
|
||||
padding: 1em ;
|
||||
border-radius: 8px ;
|
||||
}
|
||||
|
||||
table {
|
||||
border: none ;
|
||||
border-spacing: 0 ;
|
||||
border-collapse: collapse ;
|
||||
}
|
||||
|
||||
td {
|
||||
padding: 0 ;
|
||||
margin: 0 ;
|
||||
}
|
||||
|
||||
td.gutter {
|
||||
width: 4% ;
|
||||
}
|
||||
|
||||
table.columns td {
|
||||
vertical-align: top ;
|
||||
padding-bottom: 1em ;
|
||||
text-align: justify ;
|
||||
line-height: 1.25 ;
|
||||
}
|
||||
|
||||
table.book td {
|
||||
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 ;
|
||||
}
|
||||
|
||||
p.logos a:link:hover, p.logos a:visited:hover {
|
||||
background-color: inherit ;
|
||||
}
|
||||
|
||||
img {
|
||||
background-color: white ;
|
||||
}
|
118
06/lua-5.4.6/doc/luac.1
Normal file
118
06/lua-5.4.6/doc/luac.1
Normal file
|
@ -0,0 +1,118 @@
|
|||
.\" $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
|
||||
.B luac
|
||||
[
|
||||
.I options
|
||||
] [
|
||||
.I filenames
|
||||
]
|
||||
.SH DESCRIPTION
|
||||
.B luac
|
||||
is the Lua compiler.
|
||||
It translates programs written in the Lua programming language
|
||||
into binary files containing precompiled chunks
|
||||
that can be later loaded and executed.
|
||||
.LP
|
||||
The main advantages of precompiling chunks are:
|
||||
faster loading,
|
||||
protecting source code from accidental user changes,
|
||||
and
|
||||
off-line syntax checking.
|
||||
Precompiling does not imply faster execution
|
||||
because in Lua chunks are always compiled into bytecodes before being executed.
|
||||
.B luac
|
||||
simply allows those bytecodes to be saved in a file for later execution.
|
||||
Precompiled chunks are not necessarily smaller than the corresponding source.
|
||||
The main goal in precompiling is faster loading.
|
||||
.LP
|
||||
In the command line,
|
||||
you can mix
|
||||
text files containing Lua source and
|
||||
binary files containing precompiled chunks.
|
||||
.B luac
|
||||
produces a single output file containing the combined bytecodes
|
||||
for all files given.
|
||||
Executing the combined file is equivalent to executing the given files.
|
||||
By default,
|
||||
the output file is named
|
||||
.BR luac.out ,
|
||||
but you can change this with the
|
||||
.B \-o
|
||||
option.
|
||||
.LP
|
||||
Precompiled chunks are
|
||||
.I not
|
||||
portable across different architectures.
|
||||
Moreover,
|
||||
the internal format of precompiled chunks
|
||||
is likely to change when a new version of Lua is released.
|
||||
Make sure you save the source files of all Lua programs that you precompile.
|
||||
.LP
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
.B \-l
|
||||
produce a listing of the compiled bytecode for Lua's virtual machine.
|
||||
Listing bytecodes is useful to learn about Lua's virtual machine.
|
||||
If no files are given, then
|
||||
.B luac
|
||||
loads
|
||||
.B luac.out
|
||||
and lists its contents.
|
||||
Use
|
||||
.B \-l \-l
|
||||
for a full listing.
|
||||
.TP
|
||||
.BI \-o " file"
|
||||
output to
|
||||
.IR file ,
|
||||
instead of the default
|
||||
.BR luac.out .
|
||||
(You can use
|
||||
.B "'\-'"
|
||||
for standard output,
|
||||
but not on platforms that open standard output in text mode.)
|
||||
The output file may be one of the given files because
|
||||
all files are loaded before the output file is written.
|
||||
Be careful not to overwrite precious files.
|
||||
.TP
|
||||
.B \-p
|
||||
load files but do not generate any output file.
|
||||
Used mainly for syntax checking and for testing precompiled chunks:
|
||||
corrupted files will probably generate errors when loaded.
|
||||
If no files are given, then
|
||||
.B luac
|
||||
loads
|
||||
.B luac.out
|
||||
and tests its contents.
|
||||
No messages are displayed if the file loads without errors.
|
||||
.TP
|
||||
.B \-s
|
||||
strip debug information before writing the output file.
|
||||
This saves some space in very large chunks,
|
||||
but if errors occur when running a stripped chunk,
|
||||
then the error messages may not contain the full information they usually do.
|
||||
In particular,
|
||||
line numbers and names of local variables are lost.
|
||||
.TP
|
||||
.B \-v
|
||||
show version information.
|
||||
.TP
|
||||
.B \-\-
|
||||
stop handling options.
|
||||
.TP
|
||||
.B \-
|
||||
stop handling options and process standard input.
|
||||
.SH "SEE ALSO"
|
||||
.BR lua (1)
|
||||
.br
|
||||
The documentation at lua.org.
|
||||
.SH DIAGNOSTICS
|
||||
Error messages should be self explanatory.
|
||||
.SH AUTHORS
|
||||
R. Ierusalimschy,
|
||||
L. H. de Figueiredo,
|
||||
W. Celes
|
||||
.\" EOF
|
21
06/lua-5.4.6/doc/manual.css
Normal file
21
06/lua-5.4.6/doc/manual.css
Normal file
|
@ -0,0 +1,21 @@
|
|||
h3 code {
|
||||
font-family: inherit ;
|
||||
font-size: inherit ;
|
||||
}
|
||||
|
||||
pre, code {
|
||||
font-size: 12pt ;
|
||||
}
|
||||
|
||||
span.apii {
|
||||
color: gray ;
|
||||
float: right ;
|
||||
font-family: inherit ;
|
||||
font-style: normal ;
|
||||
font-size: small ;
|
||||
}
|
||||
|
||||
h2:before {
|
||||
content: "" ;
|
||||
padding-right: 0em ;
|
||||
}
|
12046
06/lua-5.4.6/doc/manual.html
Normal file
12046
06/lua-5.4.6/doc/manual.html
Normal file
File diff suppressed because it is too large
Load diff
BIN
06/lua-5.4.6/doc/osi-certified-72x60.png
Normal file
BIN
06/lua-5.4.6/doc/osi-certified-72x60.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.7 KiB |
337
06/lua-5.4.6/doc/readme.html
Normal file
337
06/lua-5.4.6/doc/readme.html
Normal file
|
@ -0,0 +1,337 @@
|
|||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>Lua 5.4 readme</TITLE>
|
||||
<LINK REL="stylesheet" TYPE="text/css" HREF="lua.css">
|
||||
<META HTTP-EQUIV="content-type" CONTENT="text/html; charset=iso-8859-1">
|
||||
<STYLE TYPE="text/css">
|
||||
blockquote, .display {
|
||||
border: solid #a0a0a0 2px ;
|
||||
border-radius: 8px ;
|
||||
padding: 1em ;
|
||||
margin: 0px ;
|
||||
}
|
||||
|
||||
.display {
|
||||
word-spacing: 0.25em ;
|
||||
}
|
||||
|
||||
dl.display dd {
|
||||
padding-bottom: 0.2em ;
|
||||
}
|
||||
|
||||
tt, kbd, code {
|
||||
font-size: 12pt ;
|
||||
}
|
||||
</STYLE>
|
||||
</HEAD>
|
||||
|
||||
<BODY>
|
||||
|
||||
<H1>
|
||||
<A HREF="http://www.lua.org/"><IMG SRC="logo.gif" ALT="Lua"></A>
|
||||
Welcome to Lua 5.4
|
||||
</H1>
|
||||
|
||||
<DIV CLASS="menubar">
|
||||
<A HREF="#about">about</A>
|
||||
·
|
||||
<A HREF="#install">installation</A>
|
||||
·
|
||||
<A HREF="#changes">changes</A>
|
||||
·
|
||||
<A HREF="#license">license</A>
|
||||
·
|
||||
<A HREF="contents.html">reference manual</A>
|
||||
</DIV>
|
||||
|
||||
<H2><A NAME="about">About Lua</A></H2>
|
||||
<P>
|
||||
Lua is a powerful, efficient, lightweight, embeddable scripting language
|
||||
developed by a
|
||||
<A HREF="http://www.lua.org/authors.html">team</A>
|
||||
at
|
||||
<A HREF="http://www.puc-rio.br/">PUC-Rio</A>,
|
||||
the Pontifical Catholic University of Rio de Janeiro in Brazil.
|
||||
Lua is
|
||||
<A HREF="#license">free software</A>
|
||||
used in
|
||||
<A HREF="http://www.lua.org/uses.html">many products and projects</A>
|
||||
around the world.
|
||||
|
||||
<P>
|
||||
Lua's
|
||||
<A HREF="http://www.lua.org/">official web site</A>
|
||||
provides complete information
|
||||
about Lua,
|
||||
including
|
||||
an
|
||||
<A HREF="http://www.lua.org/about.html">executive summary</A>
|
||||
and
|
||||
updated
|
||||
<A HREF="http://www.lua.org/docs.html">documentation</A>,
|
||||
especially the
|
||||
<A HREF="http://www.lua.org/manual/5.4/">reference manual</A>,
|
||||
which may differ slightly from the
|
||||
<A HREF="contents.html">local copy</A>
|
||||
distributed in this package.
|
||||
|
||||
<H2><A NAME="install">Installing Lua</A></H2>
|
||||
<P>
|
||||
Lua is distributed in
|
||||
<A HREF="http://www.lua.org/ftp/">source</A>
|
||||
form.
|
||||
You need to build it before using it.
|
||||
Building Lua should be straightforward
|
||||
because
|
||||
Lua is implemented in pure ANSI C and compiles unmodified in all known
|
||||
platforms that have an ANSI C compiler.
|
||||
Lua also compiles unmodified as C++.
|
||||
The instructions given below for building Lua are for Unix-like platforms,
|
||||
such as Linux and Mac OS X.
|
||||
See also
|
||||
<A HREF="#other">instructions for other systems</A>
|
||||
and
|
||||
<A HREF="#customization">customization options</A>.
|
||||
|
||||
<P>
|
||||
If you don't have the time or the inclination to compile Lua yourself,
|
||||
get a binary from
|
||||
<A HREF="http://lua-users.org/wiki/LuaBinaries">LuaBinaries</A>.
|
||||
|
||||
<H3>Building Lua</H3>
|
||||
<P>
|
||||
In most common Unix-like platforms, simply do "<KBD>make</KBD>".
|
||||
Here are the details.
|
||||
|
||||
<OL>
|
||||
<LI>
|
||||
Open a terminal window and move to
|
||||
the top-level directory, which is named <TT>lua-5.4.6</TT>.
|
||||
The <TT>Makefile</TT> there controls both the build process and the installation process.
|
||||
<P>
|
||||
<LI>
|
||||
Do "<KBD>make</KBD>". The <TT>Makefile</TT> will guess your platform and build Lua for it.
|
||||
<P>
|
||||
<LI>
|
||||
If the guess failed, do "<KBD>make help</KBD>" and see if your platform is listed.
|
||||
The platforms currently supported are:
|
||||
<P>
|
||||
<P CLASS="display">
|
||||
guess aix bsd c89 freebsd generic ios linux linux-readline macosx mingw posix solaris
|
||||
</P>
|
||||
<P>
|
||||
If your platform is listed, just do "<KBD>make xxx</KBD>", where xxx
|
||||
is your platform name.
|
||||
<P>
|
||||
If your platform is not listed, try the closest one or posix, generic,
|
||||
c89, in this order.
|
||||
<P>
|
||||
<LI>
|
||||
The compilation takes only a few moments
|
||||
and produces three files in the <TT>src</TT> directory:
|
||||
lua (the interpreter),
|
||||
luac (the compiler),
|
||||
and liblua.a (the library).
|
||||
<P>
|
||||
<LI>
|
||||
To check that Lua has been built correctly, do "<KBD>make test</KBD>"
|
||||
after building Lua. This will run the interpreter and print its version.
|
||||
</OL>
|
||||
<P>
|
||||
If you're running Linux, try "<KBD>make linux-readline</KBD>" to build the interactive Lua interpreter with handy line-editing and history capabilities.
|
||||
If you get compilation errors,
|
||||
make sure you have installed the <TT>readline</TT> development package
|
||||
(which is probably named <TT>libreadline-dev</TT> or <TT>readline-devel</TT>).
|
||||
If you get link errors after that,
|
||||
then try "<KBD>make linux-readline MYLIBS=-ltermcap</KBD>".
|
||||
|
||||
<H3>Installing Lua</H3>
|
||||
<P>
|
||||
Once you have built Lua, you may want to install it in an official
|
||||
place in your system. In this case, do "<KBD>make install</KBD>". The official
|
||||
place and the way to install files are defined in the <TT>Makefile</TT>. You'll
|
||||
probably need the right permissions to install files, and so may need to do "<KBD>sudo make install</KBD>".
|
||||
|
||||
<P>
|
||||
To build and install Lua in one step, do "<KBD>make all install</KBD>",
|
||||
or "<KBD>make xxx install</KBD>",
|
||||
where xxx is your platform name.
|
||||
|
||||
<P>
|
||||
To install Lua locally after building it, do "<KBD>make local</KBD>".
|
||||
This will create a directory <TT>install</TT> with subdirectories
|
||||
<TT>bin</TT>, <TT>include</TT>, <TT>lib</TT>, <TT>man</TT>, <TT>share</TT>,
|
||||
and install Lua as listed below.
|
||||
|
||||
To install Lua locally, but in some other directory, do
|
||||
"<KBD>make install INSTALL_TOP=xxx</KBD>", where xxx is your chosen directory.
|
||||
The installation starts in the <TT>src</TT> and <TT>doc</TT> directories,
|
||||
so take care if <TT>INSTALL_TOP</TT> is not an absolute path.
|
||||
|
||||
<DL CLASS="display">
|
||||
<DT>
|
||||
bin:
|
||||
<DD>
|
||||
lua luac
|
||||
<DT>
|
||||
include:
|
||||
<DD>
|
||||
lua.h luaconf.h lualib.h lauxlib.h lua.hpp
|
||||
<DT>
|
||||
lib:
|
||||
<DD>
|
||||
liblua.a
|
||||
<DT>
|
||||
man/man1:
|
||||
<DD>
|
||||
lua.1 luac.1
|
||||
</DL>
|
||||
|
||||
<P>
|
||||
These are the only directories you need for development.
|
||||
If you only want to run Lua programs,
|
||||
you only need the files in <TT>bin</TT> and <TT>man</TT>.
|
||||
The files in <TT>include</TT> and <TT>lib</TT> are needed for
|
||||
embedding Lua in C or C++ programs.
|
||||
|
||||
<H3><A NAME="customization">Customization</A></H3>
|
||||
<P>
|
||||
Three kinds of things can be customized by editing a file:
|
||||
<UL>
|
||||
<LI> Where and how to install Lua — edit <TT>Makefile</TT>.
|
||||
<LI> How to build Lua — edit <TT>src/Makefile</TT>.
|
||||
<LI> Lua features — edit <TT>src/luaconf.h</TT>.
|
||||
</UL>
|
||||
|
||||
<P>
|
||||
You don't actually need to edit the Makefiles because you may set the
|
||||
relevant variables in the command line when invoking make.
|
||||
Nevertheless, it's probably best to edit and save the Makefiles to
|
||||
record the changes you've made.
|
||||
|
||||
<P>
|
||||
On the other hand, if you need to customize some Lua features, you'll need
|
||||
to edit <TT>src/luaconf.h</TT> before building and installing Lua.
|
||||
The edited file will be the one installed, and
|
||||
it will be used by any Lua clients that you build, to ensure consistency.
|
||||
Further customization is available to experts by editing the Lua sources.
|
||||
|
||||
<H3><A NAME="other">Building Lua on other systems</A></H3>
|
||||
<P>
|
||||
If you're not using the usual Unix tools, then the instructions for
|
||||
building Lua depend on the compiler you use. You'll need to create
|
||||
projects (or whatever your compiler uses) for building the library,
|
||||
the interpreter, and the compiler, as follows:
|
||||
|
||||
<DL CLASS="display">
|
||||
<DT>
|
||||
library:
|
||||
<DD>
|
||||
lapi.c lcode.c lctype.c ldebug.c ldo.c ldump.c lfunc.c lgc.c llex.c lmem.c lobject.c lopcodes.c lparser.c lstate.c lstring.c ltable.c ltm.c lundump.c lvm.c lzio.c
|
||||
lauxlib.c lbaselib.c lcorolib.c ldblib.c liolib.c lmathlib.c loadlib.c loslib.c lstrlib.c ltablib.c lutf8lib.c linit.c
|
||||
<DT>
|
||||
interpreter:
|
||||
<DD>
|
||||
library, lua.c
|
||||
<DT>
|
||||
compiler:
|
||||
<DD>
|
||||
library, luac.c
|
||||
</DL>
|
||||
|
||||
<P>
|
||||
To use Lua as a library in your own programs, you'll need to know how to
|
||||
create and use libraries with your compiler. Moreover, to dynamically load
|
||||
C libraries for Lua, you'll need to know how to create dynamic libraries
|
||||
and you'll need to make sure that the Lua API functions are accessible to
|
||||
those dynamic libraries — but <EM>don't</EM> link the Lua library
|
||||
into each dynamic library. For Unix, we recommend that the Lua library
|
||||
be linked statically into the host program and its symbols exported for
|
||||
dynamic linking; <TT>src/Makefile</TT> does this for the Lua interpreter.
|
||||
For Windows, we recommend that the Lua library be a DLL.
|
||||
In all cases, the compiler luac should be linked statically.
|
||||
|
||||
<P>
|
||||
As mentioned above, you may edit <TT>src/luaconf.h</TT> to customize
|
||||
some features before building Lua.
|
||||
|
||||
<H2><A NAME="changes">Changes since Lua 5.3</A></H2>
|
||||
<P>
|
||||
Here are the main changes introduced in Lua 5.4.
|
||||
The
|
||||
<A HREF="contents.html">reference manual</A>
|
||||
lists the
|
||||
<A HREF="manual.html#8">incompatibilities</A> that had to be introduced.
|
||||
|
||||
<H3>Main changes</H3>
|
||||
<UL>
|
||||
<LI> new generational mode for garbage collection
|
||||
<LI> to-be-closed variables
|
||||
<LI> const variables
|
||||
<LI> userdata can have multiple user values
|
||||
<LI> new implementation for math.random
|
||||
<LI> warning system
|
||||
<LI> debug information about function arguments and returns
|
||||
<LI> new semantics for the integer 'for' loop
|
||||
<LI> optional 'init' argument to 'string.gmatch'
|
||||
<LI> new functions 'lua_resetthread' and 'coroutine.close'
|
||||
<LI> string-to-number coercions moved to the string library
|
||||
<LI> allocation function allowed to fail when shrinking a memory block
|
||||
<LI> new format '%p' in 'string.format'
|
||||
<LI> utf8 library accepts codepoints up to 2^31
|
||||
</UL>
|
||||
|
||||
<H2><A NAME="license">License</A></H2>
|
||||
<P>
|
||||
<A HREF="http://www.opensource.org/docs/definition.php">
|
||||
<IMG SRC="osi-certified-72x60.png" ALIGN="right" ALT="[osi certified]" STYLE="padding-left: 30px ;">
|
||||
</A>
|
||||
Lua is free software distributed under the terms of the
|
||||
<A HREF="http://www.opensource.org/licenses/mit-license.html">MIT license</A>
|
||||
reproduced below;
|
||||
it may be used for any purpose, including commercial purposes,
|
||||
at absolutely no cost without having to ask us.
|
||||
|
||||
The only requirement is that if you do use Lua,
|
||||
then you should give us credit by including the appropriate copyright notice somewhere in your product or its documentation.
|
||||
|
||||
For details, see
|
||||
<A HREF="http://www.lua.org/license.html">this</A>.
|
||||
|
||||
<BLOCKQUOTE STYLE="padding-bottom: 0em">
|
||||
Copyright © 1994–2023 Lua.org, PUC-Rio.
|
||||
|
||||
<P>
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
<P>
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
<P>
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
THE SOFTWARE.
|
||||
</BLOCKQUOTE>
|
||||
<P>
|
||||
|
||||
<P CLASS="footer">
|
||||
Last update:
|
||||
Tue May 2 20:08:55 UTC 2023
|
||||
</P>
|
||||
<!--
|
||||
Last change: revised for Lua 5.4.6
|
||||
-->
|
||||
|
||||
</BODY>
|
||||
</HTML>
|
Loading…
Add table
Add a link
Reference in a new issue