blob: 7d6a6dd0097e03dd73abb98a8ad1e31b3f0c000d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
{-# LANGUAGE QuantifiedConstraints, UndecidableInstances #-}
{-# LANGUAGE RankNTypes #-}
module T22216e where
import Data.Kind
type C :: Type -> Type -> Constraint
type D :: Type -> Type -> Constraint
class C a b
instance C () Int
class D a b
foo :: ( forall a b. ( Eq a, Num b, C a b ) => D a b
, forall a . C a Int => D a Int
)
=> ( D () Int => r ) -> r
foo r = r
|