about summary refs log tree commit diff
path: root/tests/examples/pairs-fst-snd.lam
blob: 19791adcf63bf5ec4757d309cbf37a77d7438a0a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
(\ pair fst snd .

    fst (snd (pair (pair a b) (pair c d)))

    -- Should reduce to c
)

-- pair
(\ x y f . f x y)

-- fst
(\ p . p (\ x y . x))

-- snd
(\ p . p (\ x y . y))