Commit 853cdaea authored by Simon Peyton Jones's avatar Simon Peyton Jones
Browse files

Test Trac #12081

parent 03b0b8e4
{-# LANGUAGE TypeInType #-}
module T12081 where
data Nat = Z | S Nat
class C (n :: Nat) where
type T n :: Nat
f :: (a :: T n)
T12081.hs:9:14: error:
• Type constructor ‘T’ cannot be used here
(it is defined and used in the same recursive group)
• In the kind ‘T n’
In the type signature: f :: (a :: T n)
In the class declaration for ‘C’
......@@ -15,3 +15,4 @@ test('KindLevelsB', normal, compile_fail, [''])
test('T11473', normal, compile_fail, [''])
test('T11471', normal, compile_fail, [''])
test('T12174', normal, compile_fail, [''])
test('T12081', normal, compile_fail, [''])
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment