We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
In case you want to hide two type arguments, the best I could figure out to do with the existing Exist is:
Exist
data Sample a b = Sample a b newtype Sample' a = Sample' (Exists (Sample a)) type Sample'' = Exists Sample'
Does anyone know a better way? If not, I would suggest to add something like this:
foreign import data Exists2 :: (Type -> Type -> Type) -> Type type role Exists2 representational mkExists2 :: forall f a b. f a b -> Exists2 f mkExists2 = unsafeCoerce runExists2 :: forall f r. (forall a b. f a b -> r) -> Exists2 f -> r runExists2 = unsafeCoerce
You can use it like this:
data Sample a b = Sample a b type Sample' = Exists2 Sample
The text was updated successfully, but these errors were encountered:
No branches or pull requests
In case you want to hide two type arguments, the best I could figure out to do with the existing
Exist
is:Does anyone know a better way? If not, I would suggest to add something like this:
You can use it like this:
The text was updated successfully, but these errors were encountered: