Skip to content
Writing an interpreter for the Monkey πŸ’ language in Dart
Dart Shell
Branch: master
Clone or download
mreichelt Merge pull request #9 from domesticmouse/master
Dart version upgrade and format
Latest commit c1dda44 Jul 3, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
bin
lib
test Dart version upgrade and format Jul 2, 2019
tool dummy commit to trigger first Travis build Jan 9, 2017
.gitignore Dart version upgrade and format Jul 2, 2019
.travis.yml only use stable dart, reduce git depth Jan 9, 2017
LICENSE switch to 2-Clause BSD License - more common for Dart Jan 25, 2017
README.md remove 'sh' syntax highlighting because it does not make sense Jan 25, 2017
analysis_options.yaml Dart version upgrade and format Jul 2, 2019
dartformat_analyze.sh Dart version upgrade and format Jul 2, 2019
pubspec.yaml Version bump Jul 2, 2019

README.md

Writing an Interpreter for the Monkey πŸ’ Language in Dart

Build Status

A fully working interpreter for the Monkey programming language as known from the book Writing an Interpreter in Go, written in Dart.

Install Monkey and start the REPL

With one command, you can install the monkey binary:

$ pub global activate monkey_lang
Downloading monkey_lang 0.9.1...
[...]
Installed executable monkey.

Now you can run monkey from anywhere you want!

$ monkey
Hello! This is the Monkey programming language!
Feel free to type in commands
>> let answer = fn(){ 6*7; };
>> answer()
42

Run the test suite

$ pub run test
[...]
00:00 +42: All tests passed! 

Format + analyze the code

$ ./dartformat_analyze.sh
Formatting directory lib/:
[...]
Formatting directory test/:
[...]
Analyzing [.]...
No issues found

Go ahead and have fun with Monkey!

You can’t perform that action at this time.