A simple typed functional language which compiles to Java