summaryrefslogtreecommitdiff
path: root/testsuite/tests/typecheck/should_fail/T16414.hs
blob: 592aa7de3ce5fd449c9118971d3594ef330c8d55 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE FlexibleContexts, FlexibleInstances, AllowAmbiguousTypes #-}
{-# LANGUAGE UndecidableSuperClasses #-}
module T16414 where

data I = I

class All2 x => All x
class All x => All2 x

class AllZip2 f
instance AllZip2 f

f1 :: (All x, AllZip2 I) => x -> ()
f1 = f2

f2 :: AllZip2 f => x -> ()
f2 _ = ()