HomeAbout MeProjectsContactMeow

xBASIC - A programming language written in Rust

10 Nov 2020

I have written a programming language, which I call xBASIC. It is loosely based off of QBasic, and is meant to be easy to learn.

The interpreter exists as a Rust library. This makes it easy to add user-definable logic into your Rust program. Since this is the main goal, it is designed to gracefully handle bad or malicious code. For example, it supports setting a CPU limit to prevent infinite loops from using a lot of CPU time. A basic REPL is also included.

Also, it is possible to call xBASIC code from Rust code, and call Rust code from xBASIC (but only the functions you define as xBASIC-callable).

The interpreter consists of a compiler and virtual machine. This makes it quite fast in comparison to languages which walk the AST.

For more information, and to see what the syntax looks like, check out the git repository!