CS 421: Programming Languages and Compilers
Machine Problem 4 (MP4)
MP4 will have you write a lexer for a superset of MiniJava using ocamllex.
Again, keep in mind that your solution must be compilable. If the grading program fails to compiler your code, then no points for the entire homework set of MP4. For example, if you decide not to implement the function splat (for whatever reason), you need to have it defined as:
let splat x = raise (Failure(""))

IMPORTANT: Make sure that you read the README file in the grader bundle . This file contains important information.

Please download the updated version of the grader.

Also, make sure you read the "Guide for Doing MPs".

Files
mp4.pdf (v1.1)
  Adds COMP token, corrects explanation of manual testing of solution
mp4grader.tar.gz (v1.1)
 Fixes various inconsistencies with the spec mentioned on the newsgroup
mp4common.mli
mp4-sol.mll