HaxeFoundation / haxe

Haxe - The Cross-Platform Toolkit
https://haxe.org
6.14k stars 656 forks source link

[lua] Global Var Args #10753

Open TheDrawingCoder-Gamer opened 2 years ago

TheDrawingCoder-Gamer commented 2 years ago

I'm working on a computercraft script, and how it passes arguments is via calling the file with rest args. In lua, you are meant to obtain these via

local args = {...}

Given that within the main function, you can't access global ... (i've tried) it would be nice if you could i.e. add a ...rest to the main function.

TheDrawingCoder-Gamer commented 2 years ago

apparently Sys.args does this

sanity loss

TheDrawingCoder-Gamer commented 2 years ago

that's not what Sys.args does sanity loss