class C a where { foo :: a -> Int; bar :: Int -> a; } instance C Int where { foo i = bar i; bar i = foo i; }