[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Sandboxing in Lua 5.2
- From: Lorenzo Donati <lorenzodonatibz@...>
- Date: Sat, 07 May 2011 18:47:18 +0200
On 07/05/2011 14.45, Peter Cawley wrote:
On Sat, May 7, 2011 at 1:41 PM, Roberto Ierusalimschy
loadin(env, io.lines(file, "*L"), path)
Is it mandated by the reference manual that all implementations of Lua
must return a single function rather than an iterator tuple for things
like io.lines, string.gmatch, etc?
From top of content.html, Lua 5.1.4 html docs:
"The reference manual is the official definition of the Lua language.
Thus, for what I may infer, it is also the official definition of the
default libraries (I assume that in that sentence "language" refers to
both core and libraries).
Therefore if io.lines returns a single function, that is the expected
behaviour of any "conforming" implementation, as I understand it.