Skip to search boxSkip to navigationSkip to main content

Banana Algebra: Compositional Syntactic Language Extension

Research Output:
Journal Article or Conference Article in Journal
Journal article
Peer-review

Open access

Publication Information

Output type

Research Output:
Journal Article or Conference Article in Journal
Journal article
Peer-review

Original language

English

Pages from-to (Number of pages)

Pages 1845–1870

Journal (Volume, Issue Number)

Science of Computer Programming (Volume 78, Issue 10)

Publication milestones

  • Published - 2013

Publication status

Published - 2013

ISSN

0167-6423

Publication IDs

  • Scopus: 84880309849

Abstract

We propose an algebra of languages and transformations as a means of compositional syntactic language extension. The algebra provides a layer of high-level abstractions built on top of languages (captured by context-free grammars) and transformations (captured by constructive catamorphisms).
The algebra is self-contained in that any term of the algebra specifying a transformation can be reduced to a constant catamorphism, before the transfor- mation is run. Thus, the algebra comes “for free” without sacrificing the strong safety and efficiency properties of constructive catamorphisms.
The entire algebra as presented in the paper is implemented as the Banana Algebra Tool which may be used to syntactically extend languages in an incremental and modular fashion via algebraic composition of previously defined languages and transformations. We demonstrate and evaluate the tool via several kinds of extensions.

Publication metrics

PlumX, opens in new tab

Captures
16
Citations
4