testsuite: Assert that testsuite ways are known
[ghc.git] / testsuite / tests / typecheck / should_compile / tc206.hs
1 {-# OPTIONS_GHC -fno-warn-redundant-constraints #-}
2 {-# LANGUAGE RankNTypes #-}
3
4 -- This one showed up a bug in pre-subsumption
5
6 module ShouldCompile where
7
8 class Data a where {}
9
10 type GenericQ r = forall a. Data a => a -> r
11
12 everything :: (r -> r -> r) -> GenericQ r
13 everything k f = error "urk"
14
15
16 -- | Get a list of all entities that meet a predicate
17 listify :: (r -> Bool) -> GenericQ [r]
18 listify p = everything (++)