Exploiting Attribute Grammars to Achieve Automatic Tupling

Publication date

2014

Authors

Bransen, J.ISNI 0000000419552294
Dijkstra, AtzeISNI 0000000353726385
Swierstra, DoaitseISNI 0000000052441415

Editors

Advisors

Supervisors

DOI

Document Type

Report
Open Access logo

License

Abstract

Tupling of function results is a well-known technique in functional programming to avoid multiple traversals over the same data. When expressing these programs as attribute grammars, function results are expressed as shared attributes for which tupling is done automatically. In this paper we show how we can get tupling for free by using attribute grammars as an intermediate language. We evaluate the effectiveness of the approach by showing some benchmark results.

Keywords

attribute grammars, automatic tupling, program transformation, functional programming

Citation

Bransen, J, Dijkstra, A & Swierstra, D 2014, Exploiting Attribute Grammars to Achieve Automatic Tupling. Technical Report Series, no. UU-CS-2014-013, UU BETA ICS Departement Informatica, Utrecht.