Last active
September 18, 2020 01:25
-
-
Save MarcelineVQ/e3695adaa386f378803d577ec0d0b2d2 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
`( [| ( x , y ) |] ) | |
IAlternative | |
(UniqueDefault | |
(IApp | |
(IApp | |
(IVar (UN "<*>")) | |
(IApp | |
(IApp | |
(IVar (UN "<*>")) | |
(IApp | |
(IVar (UN "pure")) | |
(IVar (NS (MkNS ["Builtin"]) (UN "MkPair"))))) | |
(IVar (UN "x")))) | |
(IVar (UN "y")))) | |
[IApp | |
(IApp | |
(IVar (UN "<*>")) | |
(IApp | |
(IApp | |
(IVar (UN "<*>")) | |
(IApp | |
(IVar (UN "pure")) | |
(IVar (NS (MkNS ["Builtin"]) (UN "Pair"))))) | |
(IVar (UN "x")))) | |
(IVar (UN "y")) | |
,IApp | |
(IApp | |
(IVar (UN "<*>")) | |
(IApp | |
(IApp | |
(IVar (UN "<*>")) | |
(IApp | |
(IVar (UN "pure")) | |
(IVar (NS (MkNS ["Builtin"]) (UN "MkPair"))))) | |
(IVar (UN "x")))) | |
(IVar (UN "y"))] |
Author
MarcelineVQ
commented
Sep 17, 2020
•
pairing : Applicative f => f a -> f b -> f (a,b)
pairing x y = %runElab check (IApp fc
(IApp fc
(IVar fc (UN "<*>"))
(IApp fc
(IApp fc
(IVar fc (UN "<*>"))
(IApp fc
(IVar fc (UN "pure"))
(IAlternative fc (UniqueDefault (IVar fc (NS (MkNS ["Builtin"]) (UN "MkPair"))))
[(IVar fc (NS (MkNS ["Builtin"]) (UN "MkPair"))), (IVar fc (NS (MkNS ["Builtin"]) (UN "Pair")))])))
(IVar fc (UN "x"))))
(IVar fc (UN "y")))
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment