Extensible Algebraic Datatypes with Defaults (2001)
Cached
Download Links
- [lamp.epfl.ch]
- [lampwww.epfl.ch]
- [lampwww.epfl.ch]
- DBLP
Other Repositories/Bibliography
| Citations: | 32 - 8 self |
BibTeX
@MISC{Zenger01extensiblealgebraic,
author = {Matthias Zenger and Martin Odersky},
title = {Extensible Algebraic Datatypes with Defaults},
year = {2001}
}
Years of Citing Articles
OpenURL
Abstract
A major problem for writing extensible software arises when recursively defined datatypes and operations on these types have to be extended simultaneously without modifying existing code. This paper introduces Extensible Algebraic Datatypes with Defaults which promote a simple programming pattern to solve this well known problem. We show that it is possible to encode extensible algebraic datatypes in an object-oriented language, using a new design pattern for extensible visitors. Extensible algebraic datatypes have been successfully applied in the implementation of an extensible Java compiler. Our technique allows for the reuse of existing components in compiler extensions without the need for any adaptations.







