Skip to content
0:00 / 0:00

#mtl#monadtransformers#lens

Next Level MTL - George Wilson - BFPG 2016-06

Brisbane Functional Programming Group

710 subscribers • 4 videos on Hallway

YouTube
  • Recommended by 2 people: 1 in engineering communities and 1 curated list.
  • Presented by George Wilson

Advanced. Deep dive for people who know the field.

10K views11 years ago2 recommendations

Programming languagesSoftware designHaskellFunctional programmingDesign patterns

George Wilson demonstrates how to use the mtl and lens libraries in Haskell to decouple functions from concrete monad transformer stacks.

Many applications leverage monad transformer stacks to control IO effects, handle error conditions, pass configurations, and more. As the requirements of these applications grow, the complexity of these transformer stacks can grow proportionally. If a specific monad transformer stack is used in type signatures, then small changes to the stack can result in large changes to the code. This talk will demonstrate tools from the mtl and the lens library that allow each function's type to describe the required parts of a transformer stack, without depending on the concrete stack itself.

Why it's here

2 people recommend this

What people say. Recommended as a classic talk on managing monad transformer stacks using classy optics in Haskell.

u/GeorgeTalksCodein r/haskell • Recommends

"Next Level mtl with Classy Optics" by George Wilson at BFPG

programming-talkscurated list on GitHubRecommends

Under “Haskell”

Next Level MTL 00:44:36 by **George Wilson** (2015)

u/hardwaresoftonin r/haskell • Mentions

Monad transformer stacks vs ReaderT Pattern Back when I started writing a very small web application, monad transformer stacks were the first solution I wrapped my head around (I say that very very loosely), so they're what I've been using up until now, but the polymorphic single-monad-stack that is the ReaderT Pattern (https://www.fpcomplete.com/blog/2017/06/readert-design-pattern) seems so much more convenient to me now. **I'm curious to know what people are using in production/hobby code**. Also, if you're wondering why I didn't mention Free monads, I drank the koolaid from the following two posts: - https://markkarpov.com/post/free-monad-considered-harmful.html - http://tech.frontrowe…