UaiLang is an initial structure of a language created with Ruby for study purposes. Structure based on the examples of the great book "How to Create Your Own Programming Language". Lexer was created using regex and used racc as parser generator.
Install deps:
$ bundle install
For changes in grammar.y it is necessary to have the racc installed:
$ gem install racc
Modify grammar.y and execute racc:
$ racc -o generator.rb grammar.y
Running codes in REPL:
$ bin/repl
Executing file code:
$ bin/repl code.uai
Example of function creation:
functrem soma(a, b) faiz
a + b
popara
soma(1, 2)
Example of if:
if true faiz
print("true")
print(1)
popara