For another approach to making this work in Haskell, see this thread of mine from 2010: https://mail.haskell.org/pipermail/haskell-cafe/2010-October...
The relevant keyword if you want to learn more here is "equirecursive types".
The relevant keyword if you want to learn more here is "equirecursive types".
(For those who don’t know, the parent poster wrote and maintained a lot of nice Haskell Libs at one point)