Bytes.same.go: def of lawful-bytes@0.1.1.0 Import: import lawful-bytes@0.1.1.0/bytes.bend as Bytes Lines 116-126 of lawful-bytes@0.1.1.0/bytes.bend: https://jend.leeeet.dev/read.txt?path=lawful-bytes@0.1.1.0/bytes.bend&start_line=116&end_line=126 import Base import lawful-bytes@0.1.1.0/defs.bend as D # ra, rb hold byte i of a and byte j of b; acc says all bytes so far matched. def same.go(n: Nat, ra: D.Bytes & U32, rb: D.Bytes & U32, +i: U32, +j: U32, acc: Bool) -> D.Bytes & (D.Bytes & Bool): match n: case 0n: (a, x) = ra (b, y) = rb (a, (b, acc)) case 1n+k: (a, +x) = ra (b, +y) = rb same.go(k, at(a, (i + 1 : U32)), at(b, (j + 1 : U32)), (i + 1 : U32), (j + 1 : U32), acc && U32.is_eq(x, y)) Uses (10): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool.and 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=Base/base.bend&name=U32.is_eq https://jend.leeeet.dev/definition.txt?path=lawful-bytes@0.1.1.0/bytes.bend&name=at https://jend.leeeet.dev/definition.txt?path=lawful-bytes@0.1.1.0/defs.bend&name=Bytes