mirror of
https://github.com/HigherOrderCO/Bend.git
synced 2024-08-15 14:50:42 +03:00
16 lines
423 B
Plaintext
16 lines
423 B
Plaintext
---
|
|
source: tests/golden_tests.rs
|
|
input_file: tests/golden_tests/simplify_matches/complex_with_case.bend
|
|
---
|
|
(map) = λa λb (match b { Tree_/Node c d e f: λg (Tree_/Node (map g c) (map g d) (map g e) (map g f)); Tree_/Leaf h: λi (Tree_/Leaf (i h)); } a)
|
|
|
|
(main) = map
|
|
|
|
(Tree_/Node) = λa λb λc λd λe (e Tree_/Node/tag a b c d)
|
|
|
|
(Tree_/Leaf) = λa λb (b Tree_/Leaf/tag a)
|
|
|
|
(Tree_/Node/tag) = 0
|
|
|
|
(Tree_/Leaf/tag) = 1
|