Pizza into Java: translating theory into practice

  title={Pizza into Java: translating theory into practice},
  author={Martin Odersky and Philip Wadler},
  booktitle={ACM-SIGACT Symposium on Principles of Programming Languages},
Pizza is a strict superset of Java that incorporates three ideas from the academic community: parametric polymorphism, higher-order functions, and algebraic data types. Pizza is defined by translation into Java and compiles into the Java Virtual Machine, requirements which strongly constrain the design space. Nonetheless, Pizza fits smoothly to Java, with only a few rough edges. 

Figures from this paper

Two Ways to Bake Your Pizza - Translating Parameterised Types into Java

Two translations for parametrically typed extensions of Java are described, the homogeneous translation maps type variables to a uniform representation and the heterogeneous translation expands the programb y specialising parameterised classes according to their arguments.

Reverse Generics - Parametrization after the Fact

By abstracting over types, generic programming enables one to write code that is independent from specific data type implementation. This style is supported by most mainstream languages, including

Transposing F to C♯: expressivity of parametric polymorphism in an object‐oriented language

We present a type‐preserving translation of System F (the polymorphic lambda calculus) into a forthcoming revision of the C♯ programming language supporting parameterized classes and polymorphic

On Extending Java

Four non-intrusive language extensions, tuples, closures, anonymous objects and iterators, are presented, which enhance the expressive power of Java and allow certain common programming idioms to be coded more naturally.

Javàight Is Type-safe | Deenitely

This paper demonstrates that machine-checking the design of non-trivial programming languages has become a reality and formalizes its abstract syntax, type system, well-formedness conditions, and an operational evaluation semantics.

Javalight is type-safe—definitely

This paper demonstrates that machine-checking the design of non-trivial programming languages has become a reality and can express and prove type soundness.

Parametric polymorphism for Java: a reflective solution

A number of inadequacies of existing implementation techniques for extending Java™ with parametric polymorphism are revealed and an adequate implementation of parametric, bounded and F-bounded polymorphism is shown to require (reflective) run-time support.

LOOJ: Weaving LOOM into Java

The LOOJ type system is sound, as demonstrated by a soundness proof for an extension of Featherweight GJ and difficulties that arise from the use of both classes and interfaces as types in Java are highlighted.

Multiparadigm extensions to Java

Recreating Leda, a multiparadigm language based on the Pascal model, but this time using Java as the language basis, with the objective to add as few new operations as possible, and to make these operations seem as close to Java as possible.

Rupiah: An extension to Java supporting match-bounded parametric polymorphism, ThisType, and exact t

This work extends Java’s type system through the addition of three constructs: match-bounded parametric polymorphism, ThisType, and exact typing, which allow a programmer to write flexible, extensible, and statically type-safe code.

Lambda: The Ultimate Imperative

We demonstrate how to model the following common programming constructs in terms of an applicative order language similar to LISP: Simple Recursion, Iteration, Compound Statements and Expressions, GO

ML for the working programmer

In teaching the methods of functional programming, how to program in Standard ML, a functional language recently developed at Edinburgh University, the author shows how to use such concepts as lists, trees, higher-order functions and infinite data structures.

Introduction to functional programming

    R. BirdP. Wadler
    Prentice Hall International series in computer science
  • 1988
This is a thorough introduction to the fundamental concepts of functional programming that includes a simple, yet coherent treatment of the Haskell class; a calculus of time complexity; and new coverage of monadic input-output.

Parameterized Types and Java

The paper discusses both the rationale for the design decisions and the impact of the extension on other parts of Java, including arrays and the class library, and an implementation of the mechanism, including extensions to the Java virtual machine, and designs for the bytecode verifier and interpreter.

An interpretation of typed OOP in a language with state

The semantics of Loop, an expressive typed object-oriented programming language with updatable instance variables, are given by a translation into a state-based language, Soop, that contains reference cells, records, and a form of F-bounded polymorphic type.

How to make ad-hoc polymorphism less ad hoc

Type classes extend the Hindley/Milner polymorphic type system, and provide a new approach to issues that arise in object-oriented programming, bounded type quantification, and abstract data types.

Dynamics in ML

Two extensions of the ML language with dynamics are presented, based on the work on the CAML implementation of ML, and the main novelty is the combination of dynamics with polymorphism.

A system of constructor classes: overloading and implicit higher-order polymorphism

A flexible type system which combines overloading and higher-order polymorphism in an implicitly typed language using a system of constructor classes – a natural generalization of type classes in Haskell is described.

The Java Language Specification

The Java Language Specification, Second Edition is the definitive technical reference for the Java programming language and provides complete, accurate, and detailed coverage of the syntax and semantics of the Java language.

What can we do about the unnecessary diversity of notation for syntactic definitions?

The population of programming languages is steadily growing, and there is no end of this growth in sight. Many language definitions appear in journals, many are found in technical reports, and