I however, have no idea how you would simulate a language in lua, so I was hoping if any of you could give me some tips/guidelines, etc.
Thanks in advance.
Now the bytecode is built (in the parser too), but it would be less complicated and cross-platform when you parse the statements into lua, not into lua bytecodes.
Yes, forgot about that, yueliang implemented it's generator in the parser, but LuaJ for example has some extra classes for that.Just to clarify, bytecode is generated after the parsing step, not during. I wouldn't really call that part of the parser. The abstract syntax tree must first be formed before you can know completely how to generate the bytecode. (Although this is probably most true for optimizations and in languages with static typing) I usually use the word "generator" for this step.