Re:Coconut: Pythonic functional programming
by eli_gottlieb on Thursday January 03, 2019 @11:57AM
(#18816628)
Please don't relax the functional purity requirement. Instead, just use an algebraic effects library in place of monads as the "sin bin", guaranteeing that anything fitting the requirements to be an effect commutes with other effects, but still requiring them to be marked in the type.
[ Parent
| on HN ]
Re:Coconut: Pythonic functional programming
by weberc2 on Thursday January 03, 2019 @12:26PM
(#18816945)
That's not meaningful to me (I'm a Haskell novice), but the thing I care about is that the compiler doesn't reject correct code (and no, "correctness" is not defined by the compiler, it's defined by the desired behavior). Whether that property comes from relaxing functional purity or some library, I don't much care.
Re:Coconut: Pythonic functional programming
by eli_gottlieb on Thursday January 03, 2019 @12:47PM
(#18817151)
There's a language community investigating those ideas here: https://www.eff-lang.org/ . As they brag:
>Effects are thus first-class citizens of Eff and can be seamlessly combined. There is no need for the do notation, no need for monad transformers, and no need to reshuffle your whole program just to read a global flag.