KURE

KURE (pronounced cure) is a Haskell hosted Domain Specific Language (DSL) for writing transformation systems based on rewrite strategies. When writing transformation systems, a significant amount of engineering effort goes into setting up plumbing to make sure that specific rewrite rules can fire. Systems like Stratego and Strafunski provide most of this plumbing as infrastructure, allowing the DSL user to focus on the rewrites rules. KURE is a strongly typed strategy control language in the tradition of Stratego and Strafunski. It is intended for writing reasonably efficient rewrite systems, makes use of type families to provide a delimited generic mechanism for tree rewriting, and provides support for efficient identity rewrite detection.

KURE was used (along with Template Haskell) to provide the basic rewrite abilities inside HERA. It was rewritten in late 2008, and is published on hackage. KURE will be used to power the next version of HERA, due for released at some point in 2009.

There are two libraries that make up the KURE tool, the core KURE combinators, and the KURE your boilerplate combinator generator.

Downloading

The best place to get KURE from is hackage.
	http://hackage.haskell.org/cgi-bin/hackage-scripts/package/kure
	http://hackage.haskell.org/cgi-bin/hackage-scripts/package/kure-your-boilerplate
or
	cabal install kure
	cabal install kure-your-boilerplate
The latest versions are kure-0.2.3 and kure-your-boilerplate-0.1.1.

KURE Related Publications

Here are publications and work in progress about KURE and rewriting in general.

Andy Gill, A Haskell Hosted DSL for Writing Transformation Systems, IFIP Working Conference on Domain Specific Languages, Jul 2009. Details, pdf, slides (pdf), BibTeX
KURE is a Haskell hosted Domain Specific Language (DSL) for writing transformation systems based on rewrite strategies. When writing transformation systems, a significant amount of engineering effort goes into setting up plumbing to make sure that specific rewrite rules can fire. Systems like Stratego and Strafunski provide most of this plumbing as infrastructure, allowing the DSL user to focus on the rewrites rules. KURE is a strongly typed strategy control language in the tradition of Stratego and Strafunski. It is intended for writing reasonably efficient rewrite systems, makes use of type families to provide a delimited generic mechanism for tree rewriting, and provides support for efficient identity rewrite detection.

Andy Gill and Graham Hutton, The worker/wrapper transformation, Journal of Functional Programming, Mar 2009. Details, pdf, Extended Version (pdf), www.workerwrapper.com, BibTeX
The worker/wrapper transformation is a technique for changing the type of a computation, usually with the aim of improving its performance. It has been used by compiler writers for many years, but the technique is little-known in the wider functional programming community, and has never been described precisely. In this article we explain, formalise, and explore the generality of the worker/wrapper transformation. We also provide a systematic recipe for its use as an equational reasoning technique for improving the performance of programs, and illustrate the power of this recipe using a range of examples.

Andy Gill, Introducing the Haskell Equational Reasoning Assistant, Proceedings of the 2006 ACM SIGPLAN Workshop on Haskell, 2006. Details, pdf, HERA Wiki Page, BibTeX
We introduce the new, improved version of the Haskell Equational Reasoning Assistant, which consists of an Ajax application for rewriting Haskell fragments in their context, and an API for scripting non-trivial rewrites.