mirror of
https://github.com/HigherOrderCO/Bend.git
synced 2024-08-15 14:50:42 +03:00
26 lines
629 B
Plaintext
26 lines
629 B
Plaintext
---
|
|
source: tests/golden_tests.rs
|
|
input_file: tests/golden_tests/encode_pattern_match/and3.bend
|
|
---
|
|
Scott
|
|
(And) = λa let (b, c, d) = a; (b λe λf (e λg (g Bool/T Bool/F) λ* Bool/F f) λ* λ* Bool/F c d)
|
|
|
|
(main) = (And (Bool/F, Bool/T, Bool/F))
|
|
|
|
(Bool/T) = λa λ* a
|
|
|
|
(Bool/F) = λ* λb b
|
|
|
|
NumScott
|
|
(And) = λa let (b, c, d) = a; (b λe switch e { 0: λf λg (f λh switch h { 0: λi (i λj switch j { 0: Bool/T; _: λ* Bool/F; }); _: λ* λ* Bool/F; } g); _: λ* λ* λ* Bool/F; } c d)
|
|
|
|
(main) = (And (Bool/F, Bool/T, Bool/F))
|
|
|
|
(Bool/T) = λa (a Bool/T/tag)
|
|
|
|
(Bool/F) = λa (a Bool/F/tag)
|
|
|
|
(Bool/T/tag) = 0
|
|
|
|
(Bool/F/tag) = 1
|