Marge Bot pushed to branch master at Glasgow Haskell Compiler / GHC
Commits:
-
c3e64915
by Simon Jakobi at 2026-03-11T15:01:31-04:00
3 changed files:
- + testsuite/tests/polykinds/T18186.hs
- + testsuite/tests/polykinds/T18186.stderr
- testsuite/tests/polykinds/all.T
Changes:
| 1 | +{-# LANGUAGE DataKinds #-}
|
|
| 2 | +{-# LANGUAGE PolyKinds #-}
|
|
| 3 | +{-# LANGUAGE ScopedTypeVariables #-}
|
|
| 4 | +{-# LANGUAGE TypeFamilies #-}
|
|
| 5 | + |
|
| 6 | +module Main (main) where
|
|
| 7 | + |
|
| 8 | +import Data.Kind (Type)
|
|
| 9 | + |
|
| 10 | +type family F :: k -> Type
|
|
| 11 | +type family B (a :: k) (b :: k) :: k
|
|
| 12 | + |
|
| 13 | +main :: IO ()
|
|
| 14 | +main =
|
|
| 15 | + \(_ :: F n) -> (undefined :: B n 1) |
| 1 | +T18186.hs:15:32: error: [GHC-83865]
|
|
| 2 | + • Expected a type,
|
|
| 3 | + but ‘B n 1’ has kind
|
|
| 4 | + ‘GHC.Internal.Bignum.Natural.Natural’
|
|
| 5 | + • In an expression type signature: B n 1
|
|
| 6 | + In the expression: undefined :: B n 1
|
|
| 7 | + The lambda expression ‘\ (_ :: F n) -> ...’
|
|
| 8 | + has one visible argument,
|
|
| 9 | + but its type ‘IO ()’ has none
|
|
| 10 | + |
| ... | ... | @@ -223,6 +223,7 @@ test('T16902', normal, compile_fail, ['']) |
| 223 | 223 | test('CuskFam', normal, compile, [''])
|
| 224 | 224 | test('T17841', normal, compile_fail, [''])
|
| 225 | 225 | test('T17963', normal, compile_fail, [''])
|
| 226 | +test('T18186', normal, compile_fail, [''])
|
|
| 226 | 227 | test('T18300', normal, compile_fail, [''])
|
| 227 | 228 | test('T18451', normal, compile_fail, [''])
|
| 228 | 229 | test('T18451a', normal, compile_fail, [''])
|