summaryrefslogtreecommitdiff
path: root/testsuite/tests/typecheck/should_compile/HardRecordUpdate.hs
blob: fc32f79bb364d50fed7129d31a39ce5e6e60beeb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
{-# LANGUAGE GADTs, TypeFamilies #-}

module HardRecordUpdate where

import Data.Kind

type F :: Type -> Type
type family F a where {}

type G :: Type -> Type -> Type -> Type
data family G a b c
data instance G a b Char where
  MkG :: { bar :: F a } -> G a Bool Char

g :: F Int -> G Float b Char -> G Int b Char
g i r = r { bar = i }