[Haskell-cafe] Re: having fun with GADT's

Anatoly Yakovenko aeyakovenko at gmail.com
Mon Sep 22 16:42:53 EDT 2008


> data Nat a where
>    Z :: Nat a
>    S :: Nat a -> Nat (S a)
>
> data Z
> data S a

I thought I was getting this, but this part is confusing.  What
exactly does declaring "data Z" do?


More information about the Haskell-Cafe mailing list