Encyclopedia > Lua

  Article Content

Lua programming language

Redirected from Lua

The Lua (pronouced LOO-ah or /lua/ in SAMPA) programming language is a bytecode interpreted lightweight glue language designed with extensible semantics as a primary goal. It is quite similar to Python in its simplicity, but it is considerably lighter. For example, while it is quite easy to use Lua to write programs in an object oriented style, there is no built in support for the paradigm other than general features for extending the language's semantics.

An interesting feature of Lua is that it has only one data structure, the table. Tables can be used as arrays, hashtables or structures with named fields, and can also simulate namespaces. There is a similar level of simplicity in the atomic datatypes -- all arithmetic is done in double-precision floating point, for example.

Lua is fast compared to most other bytecode interpreted scripting languages, and is suitable for writing stand-alone applications (although there are nowhere near as many libraries available as there are for Perl, Python or Tcl).

Like Tcl, Lua was designed primarily as an extension language which could be linked into C applications and used to extend their functionality by nonprogrammers, and is partially implemented as a small library for C to achieve this goal. One of the interesting features of the language is that it is both a language and an API for accessing the runtime state of the language's interpreter from a host C program. This means that most Lua programs run as part of a host application which is usually written in C or C++. The API allows different parts of a program to be written in C and Lua and communicate values, functions, and execution between them. A function in Lua can call a function in C and vice versa.

Lua was created by the Computer Graphics Technology Group of the Pontifical Catholic University[?] of Rio de Janeiro in Brazil. It is released as free software under BSD-like license terms, which is a non-copyleft license. It has been used in many commerical applications (e.g. in Lucas Arts' Escape from Monkey Island adventure game).

External links


In Roman mythology, Lua was the goddess the soldiers sacrificed captured weapons to. Lua also means 'moon' in Portuguese, which is what the programming language is named after.



All Wikipedia text is available under the terms of the GNU Free Documentation License

 
  Search Encyclopedia

Search over one million articles, find something about almost anything!
 
 
  
  Featured Article
Bullying

... - Wikipedia <<Up     Contents TyrantRedirected from Bullying Tyrant is a term for someone with absolute governmental power, from the Greek ...

 
 
 
This page was created in 28 ms