Programmable Rewriting Strategies in Haskell
Ralf Lämmel
Abstract
Open-access reader
Ralf Lämmel
Abstract
Open-access reader
Programmable rewriting strategies provide a valuable tool for implementing traversal functionality in grammar-driven (or schema-driven) tools. The working Haskell programmer has access to programmable rewriting strategies via two similar options: (i) the Strafunski bundle for generic functional programming and language processing, and (ii) the “Scrap Your Boilerplate” approach to generic functional programming. Basic rewrite steps are encoded as monomorphic functions on datatypes. Rewriting strategies are polymorphic functions composed from appropriate basic strategy combinators. We will briefly review programmable rewriting strategies in Haskell. We will address the following questions: What are the merits of Haskellish strategies? What is the relation between strategic programming and generic programming? What are the challenges for future work on functional strategies?
A significance statement is not available in the OpenAlex record.
A contribution statement is not available in the OpenAlex record.
Method details are not available in the OpenAlex metadata.
Findings are not separately available in the OpenAlex metadata.
Limitations are not available in the OpenAlex metadata.
Application details are not available in the OpenAlex metadata.
Programmable rewriting strategies provide a valuable tool for implementing traversal functionality in grammar-driven (or schema-driven) tools. The working Haskell programmer has access to programmable rewriting strategies via two similar options: (i) the Strafunski bundle for generic functional programming and language processing, and (ii) the “Scrap Your Boilerplate” approach to generic functional programming. Basic rewrite steps are encoded as monomorphic functions on datatypes. Rewriting strategies are polymorphic functions composed from appropriate basic strategy combinators. We will briefly review programmable rewriting strategies in Haskell. We will address the following questions: What are the merits of Haskellish strategies? What is the relation between strategic programming and generic programming? What are the challenges for future work on functional strategies?
Key concepts: Haskell, Rewriting, Programming language, Functional programming, Computer science, Combinatory logic, Generic programming, Functional reactive programming