TraversalWitness.update_sample: def of stelliferous@0.0.2.0 Import: import stelliferous@0.0.2.0/proofs/traversal_witness.bend as TraversalWitness Lines 105-118 of stelliferous@0.0.2.0/proofs/traversal_witness.bend: https://jend.leeeet.dev/read.txt?path=stelliferous@0.0.2.0/proofs/traversal_witness.bend&start_line=105&end_line=118 import Base import stelliferous@0.0.2.0/traversal_array.bend as Traversal import stelliferous@0.0.2.0/proofs/storage_witness.bend as Witness def update_sample(~Reader: Type,~Element: Data,~Value: Data,~Context: Data, ~combine: Element -> Value -> Element,~destination: Context -> U32 -> U32, +depth: Nat,-reader: Reader,+position: U32,+context: Context,-output: Array,-current: Element, -result: Reader & Value,output_evidence: Witness.Witness(Element,depth,output), sample: Sample) -> StateEvidence: match sample: case Sample{value,equation}: %Equal.sym(Reader & Value,result,(reader,value),equation) : StateEvidence StateEvidence{Array.set(Element,output,destination(context,position),combine(current,value)),(position + 1 : U32),context,{==}, Witness.write(Element,depth,output,destination(context,position),combine(current,value),output_evidence)} Uses (13): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Array https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Array.set https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Equal.sym https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Pair https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Sigma 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=stelliferous@0.0.2.0/proofs/storage_witness.bend&name=Witness https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/proofs/storage_witness.bend&name=write https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/proofs/traversal_witness.bend&name=Sample https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/proofs/traversal_witness.bend&name=StateEvidence https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/traversal_array.bend&name=update_sample