lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]



On Mar 25, 2008, at 7:09 PM, RJP Computing wrote:

Is the foreach still available? I don't see it in the table library
documentation. Sorry for such a simple question, but I like the idea of using foreach, but only if it is going to be in Lua for many versions to
come. Thanks.

• Functions table.foreach and table.foreachi are deprecated. You can use a for loop with pairs or ipairs instead.

http://www.lua.org/manual/5.1/manual.html#7.2