I E

Posts about haskell:

A Haskell "Foldable" quiz

How does GHCi respond to fold [] 42?

Read more

Turning bottom-up into top-down with Reverse State

I love bound - it makes De Bruijn indices mindlessly easy. I also love Plated for all sorts of whole-program transformations. I think they’re two indispensible tools for working with programming languages. Unfortunately, they’re not compatible.

Read more

Comonad Transformers in the Wild

A certain algorithmic puzzle website has a problem that goes like this…

Read more

Continuations From the Ground Up

It’s difficult to learn functional programming without hearing about continuations. Often they’re mentioned while talking about boosting the performance of pure functional code, sometimes there’s talk of control flow, and occasionally with ‘time-travel’ thrown in there to make it all seem more obscure. It’s all true, but let’s start from the beginning.

Read more

Why LINQ (well, C#) is Broken

LINQ is a system that provides a flexible query interface for .NET languages. It allows a user to write queries over arbitrary data using an in-built SQL-like syntax. This syntactic sugar is mapped to method calls at compile time, so any data structure that implements the correct methods can be used with LINQ.

Read more

A Practical Introduction to Monad Transformers

Monad transformers combine the functionality of two monads into one. They are often used as a way to “flatten” nested monads, but are also used to enable interactions between monads that, when used seperately, would be incredibly difficult to implement.

Read more