You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We'd like to provide instantiations for type Bool = Int# and type Bool = (# (# #) | (# #) #) but a number of limitations with primitive haskell and backpack make this impractical.
Abstract pattern synonyms (for hsig and hs-boot) blocks us from exporting any constructors, since we can't instantiate true, false :: Bool at an unlifted type, but we can implement pattern synonyms pattern True :: Bool, pattern False :: Bool, if only we could declare them in signatures.
We'd like to provide instantiations for
type Bool = Int#andtype Bool = (# (# #) | (# #) #)but a number of limitations with primitive haskell and backpack make this impractical.In particular:
Allow levity polymorphism in binding position blocks a useful implementation of
bool :: (a :: TYPE r) -> a -> Bool -> aAbstract pattern synonyms (for hsig and hs-boot) blocks us from exporting any constructors, since we can't instantiate
true, false :: Boolat an unlifted type, but we can implement pattern synonymspattern True :: Bool,pattern False :: Bool, if only we could declare them in signatures.