summaryrefslogtreecommitdiff
path: root/testsuite/tests/simplCore/should_compile/T21763a.hs
blob: 21ce638ed011202d911fa2d087c19d7dd2aa77a7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
module T21763a where

{-# NOINLINE g_imp #-}
g_imp !x = not x

f3 :: (Bool -> Bool) -> Bool -> [Bool] -> (Bool, [Bool])
-- We want to specialize for `g` to turn it into a known call.
f3 g x []     = (g x, [])
f3 g x (_:ys) = f3 g x ys

foo3 :: [Bool] -> (Bool, [Bool])
foo3 ys = f3 g_imp True ys