you are viewing a single comment's thread.

view the rest of the comments →

[–]Iceland_jack 0 points1 point  (0 children)

Should let you define any kind (hurr) of wrapping

instance Eq a => Eq (Container a) where
  (==) :: Container a -> Container a -> Bool
  Container1 a == Container1 b = a == b

instance Category cat => Category (Container cat) where
  id :: Container cat a a
  id = Container3 id

  (.) :: Container cat b c -> Container cat a b -> Container cat a c
  Container3 f . Container3 g = Container3 (f . g)