亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? manual.html

?? 支持中文變量的lua,基于lua 5.1.1源碼修改而成
?? HTML
?? 第 1 頁 / 共 5 頁
字號:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"><html><head><title>Lua 5.1 Reference Manual</title><link rel="stylesheet" href="lua.css"></head><body><hr><h1><a href="http://www.lua.org/"><img src="logo.gif" alt="" border="0"></a>Lua 5.1 Reference Manual</h1>by Roberto Ierusalimschy, Luiz Henrique de Figueiredo, Waldemar Celes<p><small><a href="http://www.lua.org/copyright.html">Copyright</a>&copy; 2006 Lua.org, PUC-Rio.  All rights reserved.</small><hr><!-- ====================================================================== --><p><h1>1 - <a name="1">Introduction</a></h1><p>Lua is an extension programming language designed to supportgeneral procedural programming with data descriptionfacilities.It also offers good support for object-oriented programming,functional programming, and data-driven programming.Lua is intended to be used as a powerful, light-weightscripting language for any program that needs one.Lua is implemented as a library, written in <em>clean</em> C(that is, in the common subset of ANSI&nbsp;C and C++).<p>Being an extension language, Lua has no notion of a "main" program:it only works <em>embedded</em> in a host client,called the <em>embedding program</em> or simply the <em>host</em>.This host program can invoke functions to execute a piece of Lua code,can write and read Lua variables,and can register C&nbsp;functions to be called by Lua code.Through the use of C&nbsp;functions, Lua can be augmented to cope witha wide range of different domains,thus creating customized programming languages sharing a syntactical framework.The Lua distribution includes a sample host program called <code>lua</code>,which uses the Lua library to offer a complete, stand-alone Lua interpreter.<p>Lua is free software,and is provided as usual with no guarantees,as stated in its license.The implementation described in this manual is availableat Lua's official web site, <code>www.lua.org</code>.<p>Like any other reference manual,this document is dry in places.For a discussion of the decisions behind the design of Lua,see the technical papers available at Lua's web site.For a detailed introduction to programming in Lua,see Roberto's book, <em>Programming in Lua</em>.<h1>2 - <a name="2">The Language</a></h1><p>This section describes the lexis, the syntax, and the semantics of Lua.In other words,this section describeswhich tokens are valid,how they can be combined,and what their combinations mean.<p>The language constructs will be explained using the usual extended BNF notation,in which{<em>a</em>}&nbsp;means&nbsp;0 or more <em>a</em>'s, and[<em>a</em>]&nbsp;means an optional <em>a</em>.Non-terminals are shown like non-terminal,keywords are shown like <b>kword</b>,and other terminal symbols are shown like `<b>=</b>&acute;.The complete syntax of Lua can be found at the end of this manual.<h2>2.1 - <a name="2.1">Lexical Conventions</a></h2><p><em>Names</em>(also called <em>identifiers</em>)in Lua can be any string of letters,digits, and underscores,not beginning with a digit.This coincides with the definition of names in most languages.(The definition of letter depends on the current locale:any character considered alphabetic by the current localecan be used in an identifier.)Identifiers are used to name variables and table fields.<p>The following <em>keywords</em> are reservedand cannot be used as names:<pre>     and       break     do        else      elseif     end       false     for       function  if     in        local     nil       not       or     repeat    return    then      true      until     while</pre><p>Lua is a case-sensitive language:<code>and</code> is a reserved word, but <code>And</code> and <code>AND</code>are two different, valid names.As a convention, names starting with an underscore followed byuppercase letters (such as <code>_VERSION</code>)are reserved for internal global variables used by Lua.<p>The following strings denote other tokens:<pre>     +     -     *     /     %     ^     #     ==    ~=    &lt;=    &gt;=    &lt;     &gt;     =     (     )     {     }     [     ]     ;     :     ,     .     ..    ...</pre><p><em>Literal strings</em>can be delimited by matching single or double quotes,and can contain the following C-like escape sequences:'<code>\a</code>' (bell),'<code>\b</code>' (backspace),'<code>\f</code>' (form feed),'<code>\n</code>' (newline),'<code>\r</code>' (carriage return),'<code>\t</code>' (horizontal tab),'<code>\v</code>' (vertical tab),'<code>\\</code>' (backslash),'<code>\"</code>' (quotation mark [double quote]),and '<code>\'</code>' (apostrophe [single quote]).Moreover, a backslash followed by a real newlineresults in a newline in the string.A character in a string may also be specified by its numerical valueusing the escape sequence <code>\<em>ddd</em></code>,where <em>ddd</em> is a sequence of up to three decimal digits.(Note that if a numerical escape is to be followed by a digit,it must be expressed using exactly three digits.)Strings in Lua may contain any 8-bit value, including embedded zeros,which can be specified as '<code>\0</code>'.<p>To put a double (single) quote, a newline, a backslash,or an embedded zeroinside a literal string enclosed by double (single) quotesyou must use an escape sequence.Any other character may be directly inserted into the literal.(Some control characters may cause problems for the file system,but Lua has no problem with them.)<p>Literal strings can also be defined using a long formatenclosed by <em>long brackets</em>.We define an <em>opening long bracket of level <em>n</em></em> as an openingsquare bracket followed by <em>n</em> equal signs followed by anotheropening square bracket.So, an opening long bracket of level&nbsp;0 is written as <code>[[</code>,an opening long bracket of level&nbsp;1 is written as <code>[=[</code>,and so on.A <em>closing long bracket</em> is defined similarly;for instance, a closing long bracket of level&nbsp;4 is written as <code>]====]</code>.A long string starts with an opening long bracket of any level andends at the first closing long bracket of the same level.Literals in this bracketed form may run for several lines,do not interpret any escape sequences,and ignore long brackets of any other level.They may contain anything except a closing bracket of the proper level.<p>For convenience,when the opening long bracket is immediately followed by a newline,the newline is not included in the string.As an example, in a system using ASCII(in which '<code>a</code>' is coded as&nbsp;97,newline is coded as&nbsp;10, and '<code>1</code>' is coded as&nbsp;49),the five literals below denote the same string:<pre>     a = 'alo\n123"'     a = "alo\n123\""     a = '\97lo\10\04923"'     a = [[alo     123"]]     a = [==[     alo     123"]==]</pre><p>A <em>numerical constant</em> may be written with an optional decimal partand an optional decimal exponent.Lua also accepts integer hexadecimal constants,by prefixing them with <code>0x</code>.Examples of valid numerical constants are<pre>     3   3.0   3.1416   314.16e-2   0.31416E1   0xff   0x56</pre><p>A <em>comment</em> starts with a double hyphen (<code>--</code>)anywhere outside a string.If the text immediately after <code>--</code> is not an opening long bracket,the comment is a <em>short comment</em>,which runs until the end of the line.Otherwise, it is a <em>long comment</em>,which runs until the corresponding closing long bracket.Long comments are frequently used to disable code temporarily.<h2>2.2 - <a name="2.2">Values and Types</a></h2><p>Lua is a <em>dynamically typed language</em>.This means thatvariables do not have types; only values do.There are no type definitions in the language.All values carry their own type.<p>All values in Lua are <em>first-class values</em>.This means that all values can be stored in variables,passed as arguments to other functions, and returned as results.<p>There are eight basic types in Lua:<em>nil</em>, <em>boolean</em>, <em>number</em>,<em>string</em>, <em>function</em>, <em>userdata</em>,<em>thread</em>, and <em>table</em>.<em>Nil</em> is the type of the value <b>nil</b>,whose main property is to be different from any other value;it usually represents the absence of a useful value.<em>Boolean</em> is the type of the values <b>false</b> and <b>true</b>.Both <b>nil</b> and <b>false</b> make a condition false;any other value makes it true.<em>Number</em> represents real (double-precision floating-point) numbers.(It is easy to build Lua interpreters that use otherinternal representations for numbers,such as single-precision float or long integers;see file <code>luaconf.h</code>.)<em>String</em> represents arrays of characters.Lua is 8-bit clean:strings may contain any 8-bit character,including embedded zeros ('<code>\0</code>') (see <a href="#2.1">&sect;2.1</a>).<p>Lua can call (and manipulate) functions written in Lua andfunctions written in C(see <a href="#2.5.8">&sect;2.5.8</a>).<p>The type <em>userdata</em> is provided to allow arbitrary C&nbsp;data tobe stored in Lua variables.This type corresponds to a block of raw memoryand has no pre-defined operations in Lua,except assignment and identity test.However, by using <em>metatables</em>,the programmer can define operations for userdata values(see <a href="#2.8">&sect;2.8</a>).Userdata values cannot be created or modified in Lua,only through the C&nbsp;API.This guarantees the integrity of data owned by the host program.<p>The type <em>thread</em> represents independent threads of executionand it is used to implement coroutines (see <a href="#2.11">&sect;2.11</a>).Do not confuse Lua threads with operating-system threads.Lua supports coroutines on all systems,even those that do not support threads.<p>The type <em>table</em> implements associative arrays,that is, arrays that can be indexed not only with numbers,but with any value (except <b>nil</b>).Tables can be <em>heterogeneous</em>;that is, they can contain values of all types (except <b>nil</b>).Tables are the sole data structuring mechanism in Lua;they may be used to represent ordinary arrays,symbol tables, sets, records, graphs, trees, etc.To represent records, Lua uses the field name as an index.The language supports this representation byproviding <code>a.name</code> as syntactic sugar for <code>a["name"]</code>.There are several convenient ways to create tables in Lua(see <a href="#2.5.7">&sect;2.5.7</a>).<p>Like indices,the value of a table field can be of any type (except <b>nil</b>).In particular,because functions are first-class values,table fields may contain functions.Thus tables may also carry <em>methods</em> (see <a href="#2.5.9">&sect;2.5.9</a>).<p>Tables, functions, threads, and (full) userdata values are <em>objects</em>:variables do not actually <em>contain</em> these values,only <em>references</em> to them.Assignment, parameter passing, and function returnsalways manipulate references to such values;these operations do not imply any kind of copy.<p>The library function <a href="#pdf-type"><code>type</code></a> returns a string describing the typeof a given value.<h3>2.2.1 - <a name="2.2.1">Coercion</a></h3><p>Lua provides automatic conversion betweenstring and number values at run time.Any arithmetic operation applied to a string tries to convertthis string to a number, following the usual conversion rules.Conversely, whenever a number is used where a string is expected,the number is converted to a string, in a reasonable format.For complete control over how numbers are converted to strings,use the <code>format</code> function from the string library(see <a href="#pdf-string.format"><code>string.format</code></a>).<h2>2.3 - <a name="2.3">Variables</a></h2><p>Variables are places that store values.There are three kinds of variables in Lua:global variables, local variables, and table fields.<p>A single name can denote a global variable or a local variable(or a function's formal parameter,which is a particular kind of local variable):<pre>	var ::= Name</pre><p>Name denotes identifiers, as defined in <a href="#2.1">&sect;2.1</a>.<p>Variables are assumed to be global unless explicitly declared local(see <a href="#2.4.7">&sect;2.4.7</a>).Local variables are <em>lexically scoped</em>:local variables can be freely accessed by functionsdefined inside their scope (see <a href="#2.6">&sect;2.6</a>).<p>Before the first assignment to a variable, its value is <b>nil</b>.<p>Square brackets are used to index a table:<pre>	var ::= prefixexp `<b>[</b>&acute; exp `<b>]</b>&acute;</pre><p>The meaning of accesses to global variables and table fields can be changed via metatables.An access to an indexed variable <code>t[i]</code> is equivalent toa call <code>gettable_event(t,i)</code>.(See <a href="#2.8">&sect;2.8</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.)<p>The syntax <code>var.Name</code> is just syntactic sugar for<code>var["Name"]</code>:<pre>	var ::= prefixexp `<b>.</b>&acute; Name</pre><p>All global variables live as fields in ordinary Lua tables,called <em>environment tables</em> or simply<em>environments</em> (see <a href="#2.9">&sect;2.9</a>).Each function has its own reference to an environment,so that all global variables in this functionwill refer to this environment table.When a function is created,it inherits the environment from the function that created it.To get the environment table of a Lua function,you call <a href="#pdf-getfenv"><code>getfenv</code></a>.To replace it,

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
一区二区三区四区乱视频| 成人丝袜18视频在线观看| 国产99一区视频免费| 欧美日韩亚洲高清一区二区| 亚洲国产成人私人影院tom| 日本系列欧美系列| 欧美日韩在线播放| 亚洲男人都懂的| 国产99久久久国产精品 | 亚洲一区av在线| 成人av在线观| 中文字幕乱码亚洲精品一区| 激情文学综合网| 日韩精品在线网站| 久久超碰97人人做人人爱| 欧美日本视频在线| 亚洲电影一级片| 在线国产电影不卡| 亚洲伊人色欲综合网| 色综合天天视频在线观看| 国产精品乱人伦| 成人综合在线观看| 日本一区二区成人| 福利一区二区在线| 国产精品毛片高清在线完整版| 国产一区二区日韩精品| 久久久久久久久岛国免费| 久久福利资源站| 久久久久久麻豆| 成人性生交大片免费看在线播放| 亚洲蜜臀av乱码久久精品 | 国产精品视频一区二区三区不卡| 久久精品国产秦先生| 精品成人免费观看| 国产在线不卡一区| 中文一区二区在线观看| av高清久久久| 亚洲国产毛片aaaaa无费看 | 成人精品鲁一区一区二区| 欧美极品aⅴ影院| 99视频有精品| 亚洲不卡在线观看| 日韩欧美自拍偷拍| 精品亚洲欧美一区| 亚洲国产高清在线| 91久久线看在观草草青青| 亚欧色一区w666天堂| 欧美一区二区啪啪| 国产精品18久久久久久久网站| 国产精品美女久久久久久久久 | 香蕉成人伊视频在线观看| 91精品欧美一区二区三区综合在 | 99久久99久久精品国产片果冻 | 在线免费视频一区二区| 亚洲第一综合色| 精品国产伦一区二区三区免费| 成人开心网精品视频| 一个色在线综合| 精品第一国产综合精品aⅴ| 国产成人在线视频播放| 一区二区三区欧美在线观看| 日韩欧美一区电影| 成人性色生活片| 日韩精品亚洲一区| 国产精品国产自产拍在线| 欧美三区在线观看| 国产精品99久| 日韩影院精彩在线| 国产精品成人免费| 日韩欧美电影在线| 色综合久久天天| 国产一区二区导航在线播放| 亚洲国产精品尤物yw在线观看| 2023国产精品| 欧美日韩美少妇| 99久精品国产| 精品一区二区三区香蕉蜜桃| 亚洲在线免费播放| 中文字幕精品—区二区四季| 91精品国产欧美一区二区18| 久久久久高清精品| 在线电影院国产精品| av亚洲产国偷v产偷v自拍| 极品少妇xxxx精品少妇| 亚洲一区二区三区中文字幕| 国产精品日日摸夜夜摸av| 欧美成人艳星乳罩| 欧美精品 日韩| 色先锋资源久久综合| 成av人片一区二区| 国产一区二区精品在线观看| 丝袜亚洲另类丝袜在线| 伊人一区二区三区| 中文字幕在线不卡一区| 欧美精品一区二区蜜臀亚洲| 欧美理论电影在线| 欧美日韩国产天堂| 欧美在线视频全部完| 91网址在线看| 不卡一区二区在线| 成人avav影音| 不卡一区二区中文字幕| 国产激情一区二区三区| 国产精品一区二区你懂的| 久久国产精品无码网站| 久久成人免费网站| 精东粉嫩av免费一区二区三区| 日本亚洲免费观看| 免费观看一级欧美片| 蜜桃精品视频在线| 久久99在线观看| 国产真实乱子伦精品视频| 国产在线视频一区二区三区| 国内精品国产成人国产三级粉色| 精品一区二区日韩| 国产精品一区二区在线观看网站| 国内精品免费**视频| 国产精品伊人色| 成人a区在线观看| 日本久久一区二区三区| 91国偷自产一区二区三区观看| 在线中文字幕不卡| 欧美肥妇毛茸茸| 久久亚洲一区二区三区四区| 国产婷婷色一区二区三区| 国产精品少妇自拍| 亚洲欧美福利一区二区| 亚洲一区精品在线| 免费观看在线色综合| 国产成人免费av在线| av一区二区三区| 欧美日韩精品福利| 精品久久一二三区| 中文字幕av一区二区三区免费看| 中文字幕一区二区三区四区不卡| 亚洲私人黄色宅男| 石原莉奈在线亚洲二区| 国产一区二区三区蝌蚪| 成人av在线电影| 欧美高清性hdvideosex| 久久久综合激的五月天| 亚洲日韩欧美一区二区在线| 日本不卡高清视频| 丁香亚洲综合激情啪啪综合| 在线亚洲免费视频| 精品欧美一区二区久久| 亚洲色图清纯唯美| 肉丝袜脚交视频一区二区| 欧美日韩成人一区二区| 精品国精品国产| 亚洲激情成人在线| 国内精品伊人久久久久av一坑| 91猫先生在线| 精品国产一区二区亚洲人成毛片 | av毛片久久久久**hd| 欧美精品 国产精品| 国产精品欧美一区喷水| 亚洲在线一区二区三区| 高清在线成人网| 制服.丝袜.亚洲.中文.综合| 国产精品美女久久久久久2018| 污片在线观看一区二区| 成人18视频日本| 精品国产乱码久久久久久图片| 亚洲综合免费观看高清完整版| 国产99久久精品| 欧美成人伊人久久综合网| 亚洲另类色综合网站| 福利一区二区在线观看| 日韩免费一区二区| 亚洲va韩国va欧美va精品| 一区二区三区成人| 国产成人超碰人人澡人人澡| 色久优优欧美色久优优| 国产精品美女久久久久aⅴ| 国产一区二区精品久久99| 8x8x8国产精品| 亚洲成人综合网站| 国产亚洲精品7777| 国产欧美日韩一区二区三区在线观看| 欧美日韩不卡视频| 日韩精品五月天| 国产成人精品一区二| 成人国产一区二区三区精品| 欧美一激情一区二区三区| 亚洲一区在线观看视频| 色综合久久中文字幕综合网| 国产欧美一区二区三区在线看蜜臀 | 奇米色777欧美一区二区| 欧美色爱综合网| 亚洲国产精品一区二区久久恐怖片 | 亚洲成人在线免费| 日本韩国一区二区三区| 亚洲视频一区二区在线| av电影在线不卡| 最好看的中文字幕久久| 成人av电影免费在线播放| 国产精品嫩草影院com| 成人v精品蜜桃久久一区| 国产色产综合色产在线视频 |