This is my implementatio of an interpreter for the rinha de compilers competition.
Although the challenge's name includes 'compilers', the organizers made their own compiler, which generates the AST. Since I'm starting from the AST, my solution is an interpreter.
It's my first time with an interpreter and I am new to Rust, so take everything here with a piece of salt.
docker build -t interpreter .
Map a file named source.rinha.json
to the container:
docker run --rm -v ./source.rinha.json:/var/rinha/source.rinha.json interpreter
- - Use command line to turn on/off memoization (clap crate)
- - Memoize only pure functions
- - Memoize binary operations
- - Apply Tail Optimization
- - Test more scenarios
- - Print closures
- - Support
Tuple