bytecode-generator implemented in lua