https://github.com/lpil/soup
A simple interpreted language written in Elixir
https://github.com/lpil/soup
functional interpreter language parser
Last synced: 10 months ago
JSON representation
A simple interpreted language written in Elixir
- Host: GitHub
- URL: https://github.com/lpil/soup
- Owner: lpil
- License: mpl-2.0
- Created: 2016-11-26T11:42:18.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2017-03-29T13:53:37.000Z (almost 9 years ago)
- Last Synced: 2025-03-24T09:21:09.762Z (10 months ago)
- Topics: functional, interpreter, language, parser
- Language: Elixir
- Homepage:
- Size: 57.6 KB
- Stars: 21
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Soup
Soup is a simple interpreted language, the runtime for which is written in
Elixir.
It looks like this:
```rust
let x = 1
let y = 2
let add = |x, y| {
x + y
}
let z = add(x, y)
```
It's largely an adaption of the Simple language from the first few chapters of
Tom Stuart's excellent [Understanding Computation][book].
Go grab a copy.
[book]: http://computationbook.com/
## Usage
```sh
# Compile the interpreter
MIX_ENV=prod mix escript.build
# Run some Souper code!
./soup priv/code/addition.soup
```
### MPL2 Licence