On Thu, Dec 20, 2007 at 07:55:47PM -0500, John Belmonte wrote:
> If I understand correctly, I think this is a misdesign of the Lua
> standard intepreter.  It should not be mapping command line argument
> words to Lua arguments precisely because there is an arbitrary (and
> relatively low) limit on chunk args.  Instead, lua should assemble the
> command line arguments into a Lua list, and pass that list to the script
> chunk as a single argument.  Since Lua list length is virtually
> unlimited, there will be no such issue with command line length.

IIRC, the lua interpreter passes arguments both as '...' and 'arg', 
while the latter is a table and is built witha C for loop not using more
then 2 stack slots, the former is built as a closure (or function call)
thus all arguments are pushend on the stack and then a lua_pcall is
performed. 

The patch (not setting '...') is easy and even discused on the lua mailing
list, but is clearly a drift from the upstream I'd like not to perform.

Cheers
-- 
Enrico Tassi



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to