git.iko.soy/rowtype-yoga/purescript-native
on 558cd4e help sign in
37 lines 602 B history raw
1test1 = \(x, y, z) -> x * y + z(x)(y)
3test2 = (\x -> x.foo false) { foo : \_ -> 1 }
5test3 = (\(x, y) -> x)(1 + 2 * (1 + 2), true && (false || false))
7k = \x -> \y -> x
9test4 = 1 `k` 2
11infixl 5 %%
13(%%) = \x -> \y -> x * y + y
15test5 = 1 %% 2 %% 3
17test6 = ((\x -> x) `k` 2) 3
19(<>) = \s1 -> \s2 -> s1 ++ s2
21test7 = "Hello" <> "World!"
23module Ops where
25 (@@) :: forall a b. (a -> b) -> a -> b
26 (@@) = \f x -> f x
28 foo :: String -> String
29 foo = \s -> s
31 test8 = foo @@ "Hello World"
33 bar = \s1 s2 -> s1 ++ s2
35test9 = Ops:foo Ops:@@ "Hello World"
37test10 = "Hello" `Ops:bar` "World"