on d82d607 help sign in
ormolu/data/examples/declaration/class/multi-parameters.hs
32 lines 515 B history raw
1{-# LANGUAGE MultiParamTypeClasses #-}
3class Foo a b where foo :: a -> b
5-- | Something.
6class Bar a b c d
7 where
8 bar ::
9 a
10 -> b
11 -> c
12 -> d
14class -- Before name
15 Baz
16 where
17 baz :: Int
19-- | Something else.
20class
21 BarBaz
22 a -- Foo
23 b -- Bar
24 c -- Baz bar
25 d -- Baz baz
26 e -- Rest
27 f where
28 barbaz ::
29 a -> f
30 bazbar ::
31 e ->
32 f