summaryrefslogtreecommitdiff
path: root/testsuite/tests/patsyn/should_compile/T8968-2.hs
blob: 2ec4d2dfb5f0eb647e33500089603287785ebc78 (plain)
1
2
3
4
5
6
7
8
9
10
{-# LANGUAGE GADTs, KindSignatures, PatternSynonyms, FlexibleContexts #-}
module ShouldCompile where

import Data.Kind (Type)

data X :: (Type -> Type) -> Type -> Type where
  Y :: (Show a) => f a -> X f (Maybe a)

pattern C :: (Show (a, Bool)) => a -> X Maybe (Maybe (a, Bool))
pattern C x = Y (Just (x, True))