A simple interpreter for the Go programming language that I wrote for my compilers course. It supports basic functionality such as arithmetic, for-loops, if statements (conditional branching), function calls, recursion, types (currently only int and bool), type return values and parameter return values. A demo program called demo.go
which demonstrates some of the functionalities is provided in /src
.
To build, simply download this repository, navigate to /src
and run the command make
in your terminal. You can run the demo program with ./goterpreter "demo.go"
, or feel free to try it out with your own Go programs.