Haskell Language Free (Const c) ~~ Either c


Example

Given

data Const c a = Const c

we have

data Free (Const c) a
     = Pure a
     | Free (Const c)

which is isomorphic to

data Either c a
     = Right a
     | Left c