What?
Naylang is the new interpreter, runtime and debugger for a subset of the Grace Programming Language. It’s still a work in progress, but it has some great features already!
How?
To use Naylang, just download the executable for the latest release and start it up in a terminal!
If you’d rather compile it from source click me!
Commands
For now, Naylang accepts three kinds of commands:
-
load
(orl
)<path>
: Open the file in<path>
, execute it, and show the resulting environment. -
exec
(ore
)<code>
: Execute the code and show the resulting environment. -
print
(orp
)<expression>
: Execute the expression and show the result.
Here’s an example execution of Naylang:
Want to contribute?
Naylang is written entirely in modern C++14.
It uses ANTLR4 for parsing, CMake as a build system and Catch as a testing framework.
If you’d like to contribute to this project, you are more than welcome to.
Feel free to submit an issue,
fork the main repo and submit a pull request with your improvements, or even shoot me an email (blorente@ucm.es) if you want some direction on where to begin.
Compilation instructions
Naylang uses standard out-of-source compilation with CMake.
It requires at least version 3 of CMake and a compiler that supports C++14 (for example, GCC6.x).
When all those dependencies are installed, just download the repo (git clone https://github.com/blorente/naylang
) and a simple sequence of commands should suffice to run the tests:
cd /root/of/repo
mkdir
build && cd build
cmake ..
make -j antlr4cpp antlr4cpp_generation_naylang
cmake ..
make -j
cd tests
chmod +x ./tests
./tests