Incorrectly parenthesized prettyprinted types
Consider
import Data.Functor.Identity
class Functor w => Comonad w where
extract :: w a -> a
duplicate :: w a -> w (w a)
instance Comonad Identity where
extract (Identity x) = x
duplicate = Identity
In GHCi we now get the following:
> :t duplicate (Identity 2)
duplicate (Identity 2) :: Num a => Identity (Identity a)
In PAKCS we get the same (correct) result:
> :t duplicate (Identity 2)
duplicate (Identity 2) :: Num a => Data.Functor.Identity (Data.Functor.Identity a)
In KiCS2, however, we (incorrectly) get:
> :t duplicate (Identity 2)
duplicate (Identity 2) :: Num a => Identity Identity a
Since this issue only occurs in KiCS2, I assume this is an issue with prettyprinting. This issue is not just cosmetic: The KiCS2 REPL relies on prettyprinted types for its generated modules and in this case the issue manifests itself in kind errors.