3 ms·
Yes, it is really cool space to explore and you can keep finding interesting gems :) >with some added () to work in non-lazy languages and to highlight that th
by pinopinopino 7y ago
Yes, it is really cool space to explore and you can keep finding interesting gems :)
>with some added () to work in non-lazy languages and to highlight that the type `Bool` is just the sum `Unit + Unit`
Nice. But it makes sense, also semantically. Booleans are about choice and the types of the sum don't carry information, so they can be unit. While left and right mean false and true.
You should also look into FoldMap lists, which are lists encode as foldMap. That was for me magic. (https://hackage.haskell.org/package/fmlist-0.9.3/docs/Data-FMList.html https://hackage.haskell.org/package/fmlist-0.9.3/docs/Data-F...)
Also you might enjoy this article: https://www.nlda-tw.nl/janmartin/papers/jmjansenLambdapaper.pdf https://www.nlda-tw.nl/janmartin/papers/jmjansenLambdapaper....