| x = 2 ' + 2 ', to6 = fail ⊦ 〈build_rec#(3; x, to6)〉 〈if to6 = fail then to := fail else to := some(Node(Leaf, to6 .t))〉 〈to3 := to, x1 := x ; if to3 = fail then to := fail else { to6 := fail ; build_rec#(2; x1, to6) ; if to6 = fail then to := fail else to := some(Node(to3 .t, to6 .t)) }〉 〈to5 := to ; if to5 = fail then to0 := fail else to0 := some(Node(Leaf, to5 .t))〉 〈to1 := to0 ; if x1 ≠ [] then to1 := fail〉 to1 = fail |
⊦
x = 2 ' + 2 ', to6 = fail ⊦ 〈x0 := x, d := 3〉 〈if is_empty(x0) then to := fail else let h = head(x0) in if h < d then to := fail else if h = d then { x0 := pop(x0) ; to := some(Leaf) } else let to0 = fail, to1 = fail in { build_rec#(d + 1; x0, to0) ; if to0 = fail then to := fail else { build_rec#(d + 1; x0, to1) ; if to1 = fail then to := fail else to := some(Node(to0 .t, to1 .t)) } }〉 〈to6 := to ; if to6 = fail then to := fail else to := some(Node(Leaf, to6 .t))〉 〈to3 := to, x1 := x0 ; if to3 = fail then to := fail else { to6 := fail ; build_rec#(2; x1, to6) ; if to6 = fail then to := fail else to := some(Node(to3 .t, to6 .t)) }〉 〈to5 := to ; if to5 = fail then to0 := fail else to0 := some(Node(Leaf, to5 .t))〉 〈to1 := to0 ; if x1 ≠ [] then to1 := fail〉 to1 = fail
[[CONCRETESIMPRULES : ()]]