Generalized bananas, lenses and barbed wire

Version on this page:5.0.2
LTS Haskell 22.30:5.2.3
Stackage Nightly 2024-07-24:5.2.3
Latest on Hackage:5.2.3

See all snapshots recursion-schemes appears in

BSD-3-Clause licensed by Edward A. Kmett
Maintained by Edward A. Kmett
This version can be pinned in stack with:recursion-schemes-5.0.2@sha256:ba985f861b5fa1680a99393e3394ee015bad67afdd0cc1df2ba28799a26df3a7,2208

Module documentation for 5.0.2


Hackage Build Status

This package includes code for functional programming with bananas, envelopes, lenses, barbed wire and all that.

Contact Information

Contributions and bug reports are welcome!

Please feel free to contact me through github or on the #haskell IRC channel on

-Edward Kmett



  • Support GHC-8.2.1
  • Fix Template Haskell derivation with non-default type renamer.
  • Add Recursive and Corecursive Natural instances, with Base Natural = Maybe.


  • Add Data.Functor.Foldable.TH module, which provides derivation of base functors via Template Haskell.


  • Renamed Foldable to Recursive and Unfoldable to Corecursive. With Foldable in Prelude in GHC 7.10+, having a needlessly conflicting name seemed silly.
  • Add support for GHC-8.0.1
  • Use Eq1, Ord1, Show1, Read1 to derive Fix, Nu and Mu Eq, Ord Show and Read instances
  • Remove Prim data family. ListF as a new name for Prim [a], with plenty of instances, e.g. Traversable.
  • Export unfix
  • Add chronomorphisms: chrono and gchrono.
  • Add distGApoT


  • Support for free 4.12.1


  • Support for GHC 7.10
  • Fixed para.


  • Support for GHC 7.7+’s generalized Typeable.
  • Faster gapo and para by exploiting sharing.


  • Compatibility with comonad and free version 4.0


  • Compatibility with transformers 0.3
  • Resolved deprecation warnings caused by changes to Data.Typeable