summaryrefslogtreecommitdiff
path: root/testsuite/tests/backpack/should_fail/bkpfail23.bkp
blob: 831ce42c721c83c2f397cfe5d3fff3d351ea210d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE GADTs, RoleAnnotations #-}
unit p where
    signature H where
        type role F phantom
        data F a
    module M where
        import H
        -- This will typecheck
        f :: (F a ~ F b) => a -> b
        f x = x
unit h where
    module H where
        -- But this is an invalid implementation of F
        type F a = ()
unit r where
    dependency p[H=h:H]