on 116a5a8 help sign in
32 lines 451 B history raw
1foo :: Int -> Int
2foo x = case x of
3 5 -> 10
4 _ -> 12
6bar :: Int -> Int
7bar x =
8 case x of
9 5 -> if x > 5
10 then 10 else 12
11 _ -> 12
13baz :: Int -> Int
14baz x = case x of 5 -> 10
15 _ -> 12
17quux :: Int -> Int
18quux x = case x of
19 x -> x
21withGuards :: Int -> Int
22withGuards x =
23 case x of
24 x | x > 10 ->
25 foo +
26 bar
27 x | x > 5 -> 10
28 _ -> 20
30funnyComment = -- comment
31 case () of
32 () -> ()