This repository contains a Langium based implementation of the Lox language.
Langium requires Node.js >=14 and npm >=7. Once you have those requirements installed, you can build the language using:
npm install
This will automatically compile the language and other sources. Afterwards you can run the language using the Run Extension
vscode launch config.
The examples/basic.lox
file contains a small sample of what the language is capable of. Try it out!
The langium grammar contains all of the magic necessary to make the Lox language run in vscode.
It contains a grammar definition of the Lox language which is transformed into a parser for that language. Langium additionally provides advanced editor features, such as code completion, goto reference/find references, folding, and more.