blob: d9b3058e1940ee50ff173337d88c6ae5f7268f7b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
{-# LANGUAGE RankNTypes, KindSignatures #-}
{-# OPTIONS_GHC -Werror #-}
-- Trac #959
module ShouldFail where
data D (f :: (* -> *) -> * -> *) (af :: * -> *) (ax :: *) =
D (af (f af ax))
data CList (f :: (* -> *) -> * -> *) (a :: *) =
RCons a (CList (D f) a)
type CycleList a = forall f. CList f a
chead :: CycleList a -> a
chead ys = case ys of (RCons x xs) -> x
|