Skip to content
This repository has been archived by the owner on May 1, 2020. It is now read-only.

epellis/esta

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

50 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Esta

CircleCI GitHub code size in bytes

Esta is a gradually typed, interpreted language and virtual machine implementation of my own design written in Rust

Interpreted: .est source code is compiled into byte code (simple assembly instructions) and run on the Esta VM.

Gradually Typed: The Esta Interpreter can infer variable type (e.g.):

var a: num = 4;     // Explicitly declare a is an int

var c = a + b;      // Since c and b have unknown types, they adopt a's type

Syntax

Esta's syntax is an LR(1) grammar that takes most of it's ideas from the C-family of languages. It is most similar to JavaScript and Go. Here is an example snippet of code:

fun multiply(a, b) {
    if a <= 0 {
        return b;
    } else {
        return b + multiply(a - 1, b);
    }
}

print(multiply(3, 4) == 12);

Blog Posts

Development

You are welcome to check the project out and try some of the demos provided.

WARNING: Please note that at it's current state, Esta is pre-alpha and is experiences radical, breaking changes daily.

git clone https://github.com/epellis/esta.git
cd esta
cargo build
RUST_LOG=esta=debug cargo run demos/hello.est

You can also measure performance by evaluating the Fibonacci Sequence using a naive recursive O(n^2) algorithm.

cargo bench

Deployment

WIP: Installer coming soon

cargo run --release my_program.est

About

Interpreted language and bytecode VM of my own design written in Rust [Unmaintained]

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages