summaryrefslogtreecommitdiff
path: root/testsuite/tests/typecheck/should_fail/T15361.hs
blob: 53ae965e21952e44c20ba0c620e387cc553f7f8e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
{-# LANGUAGE GADTs #-}
{-# LANGUAGE KindSignatures #-}
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE TypeOperators #-}
module T15361 where

import Data.Kind
import Data.Type.Equality

-- Don't report (* ~ *) here
foo :: forall (a :: Type) (b :: Type) (c :: Type).
       a :~~: b -> a :~~: c
foo HRefl = HRefl

data Chumbawamba :: Type -> Type where
  IGetKnockedDown :: (Eq a, Ord a) => a -> Chumbawamba a

-- Don't report (Eq a) here
goo :: Chumbawamba a -> String
goo (IGetKnockedDown x) = show x