Luai - Lua Interpreter

Well, could you possibly write some grammar and standards for it?

Hard to know what’s there and what to use without a set standard or definition of namespaces, keywords, and functions in the language.

For example:

It explains how you would build a function, string, number, negative (unary), etc, etc
An example:

printStatement -> "out" expression ";"

--translates to

out(1); -- prints "1"

Luau has this in their source code (look in Parser.cpp):

  • If statement
    image

  • While and Repeat loops
    image
    image

And a little bit of information:

  • If you’re looking to BUILD a programming language/interpreter later on in the future, don’t use Luau/Lua. They lack a lot of useful features used to make one.

Anyways, nice job on this, continue doing what you’re doing :grin:

1 Like