What You Needa Know about Yoneda: Profunctor Optics and the Yoneda Lemma (Functional Pearl)
Profunctor optics are a neat and composable representation of bidirectional data accessors, including lenses, and their dual, prisms. The profunctor representation exploits higher-order functions and higher-kinded type constructor classes, but the relationship between this and the familiar representation in terms of “getter” and “setter” functions is not at all obvious. We derive the profunctor representation from the concrete representation, making the relationship clear. It turns out to be a fairly direct application of the Yoneda Lemma, arguably the most important result in category theory. We hope this derivation aids understanding of the profunctor representation. Conversely, it might also serve to provide some insight into the Yoneda Lemma.
Tue 25 SepDisplayed time zone: Guadalajara, Mexico City, Monterrey change
15:00 - 16:30 | Bidirectional ProgrammingResearch Papers at Stifel Theatre Chair(s): Wouter Swierstra Utrecht University, Netherlands | ||
15:00 22mTalk | What You Needa Know about Yoneda: Profunctor Optics and the Yoneda Lemma (Functional Pearl) Research Papers Guillaume Boisseau University of Oxford, Jeremy Gibbons Department of Computer Science, University of Oxford DOI | ||
15:22 22mTalk | Incremental Relational Lenses Research Papers Rudi Horn University of Edinburgh, Roly Perera University of Glasgow, James Cheney University of Edinburgh, UK DOI | ||
15:45 22mTalk | Synthesizing Quotient Lenses Research Papers Solomon Maina University of Pennsylvania, Anders Miltner Princeton University, Kathleen Fisher Tufts University, USA, Benjamin C. Pierce University of Pennsylvania, Dave Walker Princeton University, Steve Zdancewic University of Pennsylvania DOI | ||
16:07 22mTalk | Generic Deriving of Generic Traversals Research Papers Csongor Kiss Imperial College London, Matthew Pickering University of Bristol, Nicolas Wu University of Bristol, UK DOI |