ProofShift.SGT: def of lawful-bytes@0.1.1.0 Import: import lawful-bytes@0.1.1.0/proof_shift.bend as ProofShift Lines 119-126 of lawful-bytes@0.1.1.0/proof_shift.bend: https://jend.leeeet.dev/read.txt?path=lawful-bytes@0.1.1.0/proof_shift.bend&start_line=119&end_line=126 import Base import lawful-bytes@0.1.1.0/proof_core.bend as C import lawful-words@0.1.0.0/defs.bend as W import lawful-arrays@0.1.0.0/proof_tree.bend as P import lawful-arrays@0.1.0.0/proof_index.bend as I def SGT(+len: U32, m: Nat, +tb: P.Tree, +j: U32, +p: U32, +k: U32) -> P.Tree: match m: case 0n: tb case 1n+n: +x = C.AT(len, tb, p) +j1 = (j + 1 : U32) SGT(len, n, I.set_tree(U32, tb, (j >> 2n : U32), W.put_byte(C.WD(tb, (j >> 2n : U32)), U32.to_nat((j .&. 3 : U32)), x)), j1, (j1 + k : U32), k) Uses (11): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.add https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.and https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.shrn https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.to_nat https://jend.leeeet.dev/definition.txt?path=lawful-arrays@0.1.0.0/proof_index.bend&name=set_tree https://jend.leeeet.dev/definition.txt?path=lawful-arrays@0.1.0.0/proof_tree.bend&name=Tree https://jend.leeeet.dev/definition.txt?path=lawful-bytes@0.1.1.0/proof_core.bend&name=AT https://jend.leeeet.dev/definition.txt?path=lawful-bytes@0.1.1.0/proof_core.bend&name=WD https://jend.leeeet.dev/definition.txt?path=lawful-words@0.1.0.0/defs.bend&name=put_byte