Skip to content

Kind annotation in tuple not parsed

Consider this:

{-# LANGUAGE KindSignatures #-}

foo :: (Int, Int :: *)
foo = undefined

HEAD reports

/Users/rae/temp/Bug.hs:5:18: parse error on input ‛::’

Changing the line to

foo :: (Int, (Int :: *))

fixes the problem. Note the extra parentheses.

Trac metadata
Trac field Value
Version 7.7
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Compiler (Parser)
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information