blob: 5d3adc8daaa61e85c745b200e04aabfb8ebd9fce (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
|
module overloaded_constructors
:: Tree a = Node a (Tree a) (Tree a) | TreeNil
:: List a = Cons a (List a) | ListNil
class Nil a :: a b
instance Nil Tree where Nil = TreeNil
instance Nil List where Nil = ListNil
Start = Cons 5 Nil
|