`_ <- mapM` --> `mapM_`
[ghc.git] / testsuite / tests / ghci.debugger / GADT.hs
1 data Empty
2 data NonEmpty
3
4 data SafeList x y where
5 Nil :: SafeList x Empty
6 Cons:: Eq x => x -> SafeList x y -> SafeList x NonEmpty
7 One :: Eq x => x -> SafeList x Empty -> SafeList x NonEmpty
8
9 safeHead :: SafeList x NonEmpty -> x
10 safeHead (Cons x _) = x
11
12 foo = Cons 3 (Cons 6 (Cons 9 Nil))
13
14
15 data Dict x where
16 DictN :: Num x => x -> Dict x
17 DictE :: Eq x => x -> Dict x
18
19 data Exist where
20 Exist :: forall a. a -> Exist