[HN Gopher] Freer Monads, More Extensible Effects (2015) [pdf]
       ___________________________________________________________________
        
       Freer Monads, More Extensible Effects (2015) [pdf]
        
       Author : todsacerdoti
       Score  : 67 points
       Date   : 2025-11-20 14:56 UTC (8 hours ago)
        
 (HTM) web link (okmij.org)
 (TXT) w3m dump (okmij.org)
        
       | sctb wrote:
       | (2015) More information here:
       | https://okmij.org/ftp/Haskell/extensible.
        
       | nbaksalyar wrote:
       | I strongly recommend to check all other papers and articles on
       | https://okmij.org/ftp/, every single one of them is brilliant and
       | insightful. I love the pedagogy, the writing style and clarity.
       | Oleg Kiselyov is one of the best technical writers I've
       | discovered recently.
        
       | kccqzy wrote:
       | If you are looking for real-world code for an effect system, not
       | just a PDF paper, you should probably look at the eff library:
       | https://github.com/hasura/eff
       | 
       | The acknowledgement section on that GitHub README mentions this
       | paper.
        
         | epolanski wrote:
         | Also effect-ts in TypeScript world, which is by far the most
         | popular effect system around (quite sure it has overtaken
         | Scala's ZIO from which it is inspired).
         | 
         | The ecosystem is massive.
         | 
         | Cons: TypeScript is a great type system but requires some
         | investment to get the best out of it, it's also very verbose.
         | 
         | Pros: you have access to the entirety of the TypeScript
         | ecosystem.
         | 
         | https://effect.website/
        
           | pxeger1 wrote:
           | > by far the most popular effect system around
           | 
           | Crazy claim to make without providing any evidence
        
             | epolanski wrote:
             | What other effect library or language has 6 millions +
             | downloads per month (that's more than angular) and meetups
             | popping all around the world?
        
           | Twey wrote:
           | I've stumbled across this website a few times now and every
           | time I'm surprised that despite the name it doesn't seem to
           | include (or at least document) any kind of effect system. Am
           | I just missing it? It seems to have some utilities for error-
           | handling and that's about as close as it comes.
        
         | tome wrote:
         | eff has never been released to Hackage and as far as I know
         | never used in production. I wouldn't call it "real-world code".
         | For effect systems that people do actually use in production I
         | suggest
         | 
         | * Polysemy: https://hackage.haskell.org/package/polysemy
         | 
         | * effectful: https://hackage.haskell.org/package/effectful
         | 
         | * Bluefin: https://hackage-
         | content.haskell.org/package/bluefin/docs/Blu...
         | 
         | [Disclosure: Bluefin in my effect system]
        
         | solomonb wrote:
         | `eff` is a research project that is no longer in active
         | development and never made it to production in any sense. It
         | would be AMAZING if `eff` were completed but I dont think that
         | will happen at this point.
         | 
         | `eff` is based on delimited continuations (which Alexis had to
         | build into GHC), it is not using `Freer`. If you want to look
         | at an effect system in Haskell that actually has been used in
         | production AND is based on this paper then look at `freer-
         | simple`: https://hackage.haskell.org/package/freer-simple
         | 
         | No it is not high performance, but neither are any other
         | Haskell effect systems and performance is relative to your
         | problem domain. It also has the benefit of being implemented
         | very similarly to Oleg's paper making it a lot easier to learn
         | from then most other options.
        
           | tome wrote:
           | > No it is not high performance, but neither are any other
           | Haskell effect systems
           | 
           | This is not true. IO-wrapper effect systems (in practice,
           | effectful or Bluefin) have as good performance as Haskell's
           | IO monad, that is to say as good as you can get in Haskell.
        
         | Twey wrote:
         | As far as I know the shiniest implementations in the effect
         | typing world at the moment are Koka and Effekt, which are both
         | languages in their own right. They each have their own ideas
         | about implementation to make effects (mostly) zero-cost.
         | 
         | https://koka-lang.github.io/ https://effekt-lang.org/
         | 
         | Frank is pretty old now but perhaps a simpler implementation:
         | https://github.com/frank-lang/frank
        
       | wavemode wrote:
       | I've always loved this paper. Great reading if you're interested
       | in implementing an effect system from scratch. Though rather
       | overkill if you're just interested in using one.
        
       ___________________________________________________________________
       (page generated 2025-11-20 23:00 UTC)