Linear lint error in linear-generics
The following module, taken from linear-generics, fails Core Lint because of a linearity error in the desugarer output:
{-# LANGUAGE LinearTypes, GADTSyntax #-}
module LinearL where
import GHC.Types (Multiplicity (..))
import Data.Kind (Type)
data T :: Multiplicity -> Type where
MkT :: () %m-> T m
unMkT :: T m %n-> ()
unMkT (MkT x) = x
Fix incoming.