law ce

lawful-fields@0.1.1.0 · proof_cut.bend:888

import lawful-fields@0.1.1.0/proof_cut.bend as ProofCut
import Base
import lawful-bytes@0.1.1.0/defs.bend as D
import lawful-fields@0.1.1.0/defs.bend as F
import lawful-fields@0.1.1.0/fields.bend as K
import lawful-bytes@0.1.1.0/proof_core.bend as C
import lawful-arrays@0.1.0.0/proof_tree.bend as P

888law ce:
889  for +n: Nat
890  for +len: U32
891  for +t: P.Tree<U32>
892  for +d: Nat
893  for +from: U32
894  for +to: U32
895  for +sep: U32
896  for +h: {D.ok(C.BT(len, t), d) == True{} : Bool}
897  for +hft: {U32.is_le(from, to) == True{} : Bool}
898  for +ht: {Nat.is_le(U32.to_nat(to), D.size(C.BT(len, t))) == True{} : Bool}
899  for +hs: {U32.is_lt(sep, 256) == True{} : Bool}
900  {F.nats(Pair.snd(D.Bytes, List<&2, U32>, K.cut(C.BT(len, t), from, to, sep, n))) == List.take(&2, Nat, F.ends(F.split(D.slice(D.view(C.BT(len, t)), U32.to_nat(from), Nat.sub(U32.to_nat(to), U32.to_nat(from))), sep), U32.to_nat(from)), n) : List<&2, Nat>}

Uses (36)

Used by (1)