Created
July 28, 2018 13:14
-
-
Save Lysxia/97fbf2514cfb98878d6a9903acfb9ee3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Uncurry f ts r where | |
uncurry_ :: f -> NP I ts -> r | |
instance Uncurry f xs r => Uncurry (t -> f) (t ': ts) r where | |
uncurry_ f (a :* as) = uncurry_ (f a) as | |
instance (s ~ r) => Uncurry s '[] r where | |
uncurry_ z Nil = z |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment