Talk:Lua (programming language)

From Wikipedia, the free encyclopedia
Jump to: navigation, search

Confusing "Example" in 4.1[edit]

Marked as ambiguous the example from the section on the C API stack:

"Negative indices indicate offsets from the top of the stack (for example, −1 is the last element) ..."

The use of "last" just confused me more. Last added, or last to be removed? Judging from the preceding text, I'd guess it's the former, in which case I suggest this be changed to "for example, -1 is the most recently added element", or even "the last element added". It might also be worth mentioning whether positive indices are zero-indexed (is 0 or 1 the bottom-most element?) — Preceding unsigned comment added by (talk) 18:08, 20 January 2015 (UTC)

Historic Acronym?[edit]

I know it is explicitly stated on the Lua webpage that it is not an acronym[1], however lua.h in the versions prior to 3.0[2] all seem to have a variation of the following header:


    • LUA - Linguagem para Usuarios de Aplicacao
    • Grupo de Tecnologia em Computacao Grafica
    • TeCGraf - PUC-Rio
    • $Id: lua.h,v 3.32 1996/11/20 13:49:32 roberto Exp $
  • /

Correct me if I'm wrong, but isn't that "Language for Users of Applications"? -- (talk) 14:21, 5 September 2015 (UTC)

Hi, yes. Linguagem para Usuários de Aplicação can be translated as "Language for Application Users", but according to this e-mail exchange [3] [4], it was just an internal joke among the Brazilian developers, never meant to become an official acronym. Maybe this could be cited in the article. —capmo (talk) 16:27, 5 September 2015 (UTC)


Why is there a list of things done in Lua? Will it ever be complete? If not, what's it for?

Neither C, Java, Perl nor Ruby have such a list. That lets me think the list is some kind of ego boost, telling everyone how very à la mode the language is.

Let's get rid of the list.- (talk) 18:40, 7 September 2015 (UTC)

Regular expression pattern matching[edit]

Apparently, Lua has a regex-like pattern matching, but they don't use the term "Regular expression"; it looks like they purposefully do so. See --Jerome Potts (talk) 14:48, 10 November 2016 (UTC)

Strictly, the Lua language does not support regular expressions as a syntactic construct in the way that Perl et al do. The Lua standard String library does include pattern matching functions, but the syntax is a lot more limited than the standard or common PCRE variants. -- TerryE (talk) 18:59, 10 November 2016 (UTC)
Thanks. It seems to me that an article on a scripting language should indicate whether it supports/uses regexes ; i'm thinking of that as pretty much of a requirement. In this case, a mention of pattern matching should be present, and express whether it is regex-like or not. --Jerome Potts (talk) 21:16, 10 November 2016 (UTC)