Data Types and Pattern Matching by Function Application

It is generally known that algorithms can be expressed using simple function applications only. In this paper we will show that it is possible to make a systematic translation of algebraic data types and pattern-based function definitions, like they are used in most modern functional programming languages, to function applications. The translated algebraic data types closely resemble the original type definitions. We developed an efficient interpreter for the resulting functions. The interpreter has a simple and elegant structure because there is no need for special handling of data structures and pattern matching. Despite the lack of optimisations its performance turns out to be competitive in a comparison with other interpreters like Hugs, Helium, GHCi and Amanda.