Control Flow in Haskell (0) - Introduction
Tags: Haskell, Control Flow | December 12, 2016 |
I have been working on improving the way we describe the control flow of Haskell programs. As the post is rather long, it is split in several parts:
- State of the art: briefly survey the state of the art (unchecked exceptions, Either, EitherT, etc.) and the issues I am trying to solve.
- Variant: describe a new
Variant
data type (a parameterized open sum type). Basically a value of typeVariant '[X,Y,Z]
can contain any value whose type isX
,Y
orZ
. - Flow with Variant: describe how we can use the
Variant
data type to solve control flow issues.