lua-users home
lua-l archive

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


>Any way to get the source back?

Sorry, no. The best you can do is run luac -l on the compiled files and
read the bytecode, specially the comments -- they give you the names of the
variables and the values of constants. Names of local variables will no
appear, but you can recompile src/luac/print.c to show them. It's a simple
switch. You'll still have to keep track of scopes by hand.

Bottom line: sorry, the source is gone forever. You may be able to recreate
it, but it'll be hard work, specially since you have 60 files!

> (Any chance of getting the bytecode format formalised?

As we have said before, Lua's VM is a tool for implementing Lua, not a
general-purpose VM. So it changes as our needs changes. Formalizing the VM
would imply freezing it, something we can't do.
--lhf