Skip to content

Interpreter for Monkey Language - as described in "Writing an Interpreter in Go" by Thorsten Ball

Notifications You must be signed in to change notification settings

tomasger/monkeylang

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

monkeylang

monkeylang is a repository for an interpreter of a custom programming language as seen in Thorsten Ball's book "Writing an Interpreter in Go".

The code follows the book closely, but I intend to apply cleaner code practices if/when possible and implement other useful features that have been mentioned, but are out of the scope of this book.

Usage

Run the program:

go run .

monkeylang currently prints out the token representation of the entered statements. Example:

Welcome to monkeylang!
This prompt now accepts your commands:
>> let x = "asd";
{Type:LET Literal:let}
{Type:IDENT Literal:x}
{Type:= Literal:=}
{Type:ILLEGAL Literal:"}
{Type:IDENT Literal:asd}
{Type:ILLEGAL Literal:"}
{Type:; Literal:;}

About

Interpreter for Monkey Language - as described in "Writing an Interpreter in Go" by Thorsten Ball

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages