Lunar programming language
A PVM (Python VM) language, directly compiling to python native AST.
Goals
-
Lexical analysis (Completed)
-
Syntax parser (Implemented but not fully)
-
Functions (Semi)
-
Function call (Semi)
-
Literals
- Integers
- Stings
- Identifiers
- Constants
-
Operators (Added tokens, not all impl'd)
- Cmp
- Assign
- Bit
- Arithmetic
-
More python equivelents
-
Type checking
-
Compile to LLVM IR (switch later)
How to use
Firstly, install
Use which ever flavour you want. Some examples-
poetry add llunar
pip install llunar
Second, run
poetry run python -m llunar examples/hello_world.lr
python -m llunar examples/hello_world.lr
Third, profit??
Note: If you want to view the AST run
poetry run python -m llunar examples/hello_world.lr --dump ast
It'll then write to ast
and put the contents in that file.