I remember seeing HVM on here a year or two back when it came out and it looked intriguing. Exciting to see something being built on top of it!<p>I would say that the play on words that gives the language its name ("Bend") doesn't really make sense...<p><a href="https://github.com/HigherOrderCO/bend/blob/main/GUIDE.md">https://github.com/HigherOrderCO/bend/blob/main/GUIDE.md</a><p>> Bending is the opposite of folding. Whatever fold consumes, bend creates.<p>But in everyday language bending is not the opposite of folding, they are more or less the same thing. Why not "unfold", which also has a connotation of "the process of happening" as well as merely the opposite of folding?<p>I have a question about the example code and output for bending:<p><pre><code> type Tree:
Node { ~lft, ~rgt }
Leaf { val }
def main():
bend x = 0:
when x < 3:
tree = Tree/Node { lft: fork(x + 1), rgt: fork(x + 1) }
else:
tree = Tree/Leaf { val: 7 }
return tree
tree = fork(0)
tree = ![fork(1), fork(1)]
tree = ![![fork(2),fork(2)], ![fork(2),fork(2)]]
tree = ![![![fork(3),fork(3)], ![fork(3),fork(3)]], ![![fork(3),fork(3)], ![fork(3),fork(3)]]]
tree = ![![![7,7], ![7,7]], ![![7,7], ![7,7]]]
</code></pre>
Where does the initial "tree = fork(0)" come from?