| P. Wadler. E#cient Compilation of Pattern Matching. In S. Peyton-Jones, editor, The Implementation of Functional Programming Languages, pages 78#103. Prentice Hall, 1987. |
....code and the result of translating smaller patterns. This can translation can be tedious for a human to perform, and can be di#cult to maintain. However, both would be easily implemented as mechanical program transformations, since they mirror the well understood problem of pattern compilation [5]. Fortunately, empirical and anecdotal evidence both suggest that this kind of deep pattern matching is rare. For instance, when converting approximately the 10,000 lines typechecker and support code in TILT, we only needed about 10 non trivially reworked patterns because of the curtain s limited ....
P. Wadler. E#cient compilation of pattern matching, 1987.
....we could use the construct to match constants. 3. It allows us to extend the de constructors by de ning c # functions. 4. It allows arbitrary control structures, with the pattern combinator as a parameter. Although standard pattern matching can also be understood as merely syntactic sugar [Wad87a], this approach is much simpler. The syntax is not as clean as standard pattern matching because everything is explicit. There are a couple ways to make things syntactically nicer (closer to regular patterns) One, we could allow for dropping the = in the =e construct: for literals (integer, ....
Philip Wadler. Ecient compilation of pattern-matching. In S. L. Peyton Jones, editor, The Implementation of Functional Programming Languages, chapter 5. Prentice-Hall International, 1987.
....number of non default clauses in the simple matchings produced is bounded by the sum of the sizes of the initial patterns. Taking the default clauses into account, the size of the output automaton is bounded by twice the size of the input program. Readers already familiar with [Augustsson 1985; Wadler 1987] will notice the similarities between the D scheme and the algorithms proposed by these authors. Nevertheless, there are two di erences. First, the D scheme chooses an arbitrary discriminating column at step (2) whereas Augustsson and Wadler alogrithms systematically select the leftmost column. ....
Wadler, P. 1987. EÆcient compilation of pattern matching. In Peyton Jones S. L. , The Implementation of Functional Programming Languages, Chapter 6. Prentice-Hall.
No context found.
P. Wadler. E#cient Compilation of Pattern Matching. In S. Peyton-Jones, editor, The Implementation of Functional Programming Languages, pages 78#103. Prentice Hall, 1987.
Online articles have much greater impact More about CiteSeer.IST Add search form to your site Submit documents Feedback
CiteSeer.IST - Copyright Penn State and NEC