Clone.certify: def of bendtorch-core@0.1.0.0 Import: import bendtorch-core@0.1.0.0/src/storage/clone.bend as Clone Lines 37-47 of bendtorch-core@0.1.0.0/src/storage/clone.bend: https://jend.leeeet.dev/read.txt?path=bendtorch-core@0.1.0.0/src/storage/clone.bend&start_line=37&end_line=47 import Base import bendtorch-core@0.1.0.0/src/storage/model.bend as Model def certify(-T: Data, +d: Nat, array: Array, valid: Model.Balanced(T, d, array)) -> Cloned: match d array: case 0n ALeaf{+value}: Cloned{ALeaf{value}, ALeaf{value}, {==}, {==}, {==}, Unit{}, Unit{}} case 0n ANode{xs, ys}: match valid: case 1n+p ALeaf{value}: match valid: case 1n++p ANode{xs, ys}: (ex, ey) = valid join(T, p, xs, ys, certify(T, p, xs, ex), certify(T, p, ys, ey)) Uses (7): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Array https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Sigma https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Unit https://jend.leeeet.dev/definition.txt?path=bendtorch-core@0.1.0.0/src/storage/clone.bend&name=Cloned https://jend.leeeet.dev/definition.txt?path=bendtorch-core@0.1.0.0/src/storage/clone.bend&name=join https://jend.leeeet.dev/definition.txt?path=bendtorch-core@0.1.0.0/src/storage/model.bend&name=Balanced