Commit db039a4a authored by Ryan Scott's avatar Ryan Scott Committed by Marge Bot

Add regression test for #15918

The test case in #15918 no longer triggers an `ASSERT` failure on
GHC HEAD, likely due to commit
68278382 (`Make a smart mkAppTyM`).
This patch adds a regression test for #15918 to finally put it to
rest.
parent c19a401d
Pipeline #3155 passed with stages
in 434 minutes and 5 seconds
{-# Language PolyKinds #-}
{-# Language TypeFamilies #-}
{-# Language ConstraintKinds #-}
{-# Language FlexibleContexts #-}
{-# Language QuantifiedConstraints #-}
{-# Language UndecidableInstances #-}
module T15918 where
import Data.Kind
class Rev f where
rev :: f a
instance (forall xx. cls xx => Rev xx) => Rev (Build cls) where
rev = undefined
data Build :: ((k -> Type) -> Constraint) -> (k -> Type)
uu = rev :: Build [] a
T15918.hs:19:19: error:
• Expected kind ‘(k0 -> *) -> Constraint’,
but ‘[]’ has kind ‘* -> *’
• In the first argument of ‘Build’, namely ‘[]’
In an expression type signature: Build [] a
In the expression: rev :: Build [] a
......@@ -20,3 +20,4 @@ test('T15359', normal, compile, [''])
test('T15359a', normal, compile, [''])
test('T15625', normal, compile, [''])
test('T15625a', normal, compile, [''])
test('T15918', normal, compile_fail, [''])
Markdown is supported
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