[go: up one dir, main page]

Skip to content

purtroppo/MiniJava

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Interpreter for MiniJava

aka I still live to tell the tale.

This is an implementation of an interpreter for MiniJava, done for the Compilers course at Ca' Foscari University of Venice, master's degree in Computer science. It's written in Ocaml. I had a lot of fun.

Usage

On Unix systems, type `make` to compile the whole thing; type `make test` instead to interpret the two pieces of MiniJava code described below.

Tests

Two pieces of MiniJava code are included to test the interpreter:

  • test1.java tests methods with or without parameters, objects, arrays, arrays of objects, arrays of arrays. It's a small beast, but a beast nonetheless.
  • test2.java tests arithmetic operations, booleans, conditionals. It's the easy-going brother of test1.

The irony of extending class Europe with class England is not lost to me.

What's next

A few things. Some comments are in Italian - just skip them until I translate them. The code could be restructured to be more compact and less redundant but I love it anyway.

About

Interpreter for MiniJava

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published