reifyRoles includes kind parameters
@songzh reported to me via email that
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE TypeFamilies #-}
import Language.Haskell.TH
data Proxy a = Proxy
yields
> $(reifyRoles ''Proxy >>= stringE.show)
"[PhantomR]"
while adding {-# LANGUAGE PolyKinds #-}
to the module above will lead to
$(reifyRoles ''Proxy >>= stringE.show)
"[NominalR,PhantomR]"
This is confusing.
Given that (non-degenerate) invisible parameters are always nominal, we might imagine changing reifyRoles
to skip invisible parameters. But this would be backward-incompatible and needlessly disruptive -- especially if we ever decide to allow non-nominal invisible parameters. So I argument for simply documenting this.
Patch coming very shortly.