Introduction - andre-1337/loxpp GitHub Wiki
Lox++ is a dynamically-typed programming language that is based on Bob Nystrom's Lox. It adds a variety of useful features, such as:
- Pattern matching
- Dictionaries and arrays (alongside with a spread operator to join several dictionaries or arrays)
- Throwable errors, alongside with
try/catch - Traits and abstract methods that must be implemented
- Namespaces and imports
- Enumerators with variants (W.I.P.)
- Lazily evaluated expressions
- Static methods
- For-in loops, alongside with an
Iterabletrait that actually provides functionality and tells the interpreter that the object can be iterated with for-in - Lambda expressions
- Overloadable operator methods for classes
- A fairly big standard library
The language aims to have a clean and concise syntax, familiar to JavaScript users and with some resemblance to Rust in some parts. I've been working on the language for a few months now, because I love how easy Lox is to work on and add new features to. It is NOT recommended to use the language for production, although you can use it and explore it on your own and create your own little projects.
Please do take a look at this wiki, explore the functionalities provided by the language and try it yourself! Feel free to open issues or pull requests if you wish to report bugs/errors or improve Lox++!