lens-family-core

Haskell 98 Lens Families

Version on this page:1.2.3
LTS Haskell 22.43:2.1.3
Stackage Nightly 2024-12-07:2.1.3
Latest on Hackage:2.1.3

See all snapshots lens-family-core appears in

BSD-3-Clause licensed by Russell O'Connor
Maintained by Russell O'Connor
This version can be pinned in stack with:lens-family-core-1.2.3@sha256:447c296620a861b5a9bb4d3caf0ebe37933a3eb901eb8bf553da8eac82ea19e4,2008
Used by 3 packages in lts-13.19(full list with versions):

This package provides first class(†) functional references. In addition to the usual operations of getting, setting and composition, plus integration with the state monad, lens families provide some unique features:

  • Polymorphic updating

  • Traversals

  • Cast projection functions to read-only lenses

  • Cast "toList" functions to read-only traversals

  • Cast semantic editor combinators to modify-only traversals.

(†) For optimal first-class support use the lens-family package with rank 2 / rank N polymorphism. Lens.Family.Clone allows for first-class support of lenses and traversals for those who require Haskell 98.