lua-users home
lua-l archive

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


Hi all,

David Given wrote:
On Thursday 05 January 2006 16:46, Lisa Parratt wrote:
[...]
Could a coordinated project to create a standard library, seperate from
the main Lua distribution, that dumps/undumps in a universal format, be
useful?
Could this universal format be, in fact, Lua source code?

I'll second that! :-)

That way, the undump code would automatically exist in every Lua interpreter, and the dump code would take a compiled Lua chunk and turn it into a Lua string that would produce the same byte-code when compiled. (But not necessarily the same source code that you started out with.)

Plain text is, after all, the ultimate portable file format...

After reading all the suggestions in the previous e-mails, I don't see why bytecode need to be sent instead of the source code. Lua bytecode doesn't offer any significant size, performance or security advantage over source code.

--
Cheers,
Kein-Hong Man (esq.)
Kuala Lumpur, Malaysia