Independently Extensible Solutions to the Expression Problem

Matthias Zenger and Martin Odersky, EPFL Lausanne

presented at FOOL 12.

EPFL Technical Report IC/2004/33.

Abstract

The expression problem is fundamental for the development of extensible software. Many (partial) solutions to this problem have been proposed in the past, but the question of how to use different, independent extensions jointly has received less attention so far. This paper proposes solutions to the expression problem that make it possible to combine independent extensions in a flexible, modular, and type-safe way. The solutions, formulated in the programming language Scala, are affected with only a small implementation overhead and are relatively easy to implement by hand.

Paper

in .ps.gz or .pdf format.

Note:

The code in that paper was written for Scala version 1; it does not compile under Scala version 2. The following two files contain the updated version:

abstract-data-mixin.scala

abstract-operation-mixin.scala

BibTeX Entry

@InProceedings{odersky-zenger:fool12,
  author =       {Martin Odersky and Matthias Zenger},
  title =        {Independently Extensible Solutions to the Expression Problem},
  booktitle =    {Proc. FOOL 12},
  year =         2005,
  month =        jan,
  note =         {\verb@http://homepages.inf.ed.ac.uk/wadler/fool@}
}
  

¤
Maintained by Martin Odersky.
Last updated: 29 June 2006.