Get the latest tech news

Lens: Lenses, Folds and Traversals


Lenses, Folds and Traversals

The combinators in Control.Lens provide a highly generic toolbox for composing families of getters, folds, isomorphisms, traversals, setters and lenses and their indexed variants. What is provided in this library is a number of stock lenses and traversals for common haskell types, a wide array of combinators for working them, and more exotic functionality, ( e.g. getters, setters, indexed folds, isomorphisms). Combinators are included that are based on Neil Mitchell's uniplate, but which have been generalized to work on or as lenses, folds, and traversals.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of Lens

Lens

Photo of Lenses

Lenses

Photo of Folds

Folds

Related news:

News photo

Snapchat adds a new subscription tier for Lenses

News photo

The Illusion of Thinking: Strengths and Limitations of Reasoning Models

News photo

Google Shows Off Android XR Smart Glasses with In-Lens Display