This page relates to a transformation which takes a higher-order program, and a produces an equivalent first-order program. Unlike Reynolds style defunctionalisation, it does not introduce any new data types, and the results are more amenable to subsequent analysis operations. Our transformation is implemented, and works on a Core language to which Haskell programs can be reduced. Our method cannot always succeed in removing all functional values, but in practice is remarkably successful.
- Released version
- git clone https://github.com/ndmitchell/firstify.git
- Losing Functions without Gaining Data - from Haskell Symposium 2009 (abstract) (bibtex)
- First Order Haskell - from BCTCS 2007 (bibtex)