16 Jun
2017
16 Jun
'17
3:55 p.m.
Dear Basex team, today I was trying out hof:until with the code [1]. According to the documentation [2] it should behave like a sort of "do code until condition" and I'd expect it to return 1 but I get 0 instead thus it rather seems like a "until condition do code". Are my expectations wrong? Thanks, Marco. [1] declare function local:pred($res){ true() }; declare function local:loop($val){ $val + 1 }; hof:until(local:pred#1, local:loop#1, 0) [2] Applies the function|$f|to the initial value|$start|until the predicate|$pred|applied to the result returns|true()|.