1 --!!! an example Simon made up
3 module ShouldSucceed where
5 f x = (x+1, x<3, g True, g 'c')
7 g y = if x>2 then [] else [y]
9 Here the type-check of g will yield an LIE with an Ord dict
10 for x. g still has type forall a. a -> [a]. The dictionary is
13 It should be ok to add the signature:
16 f2 x = (x+1, x<3, g2 True, g2 'c')
20 g2 y = if x>2 then [] else [y]
25 f3 x = (x+1, x<3, g3 True, g3 'c')
28 g3 = (\ y -> if x>2 then [] else [y])::(a -> [a])