PROOF.n64_split: def of bend-osdev-crc@0.1.0.0 Import: import bend-osdev-crc@0.1.0.0/PROOF.bend as PROOF Lines 40-45 of bend-osdev-crc@0.1.0.0/PROOF.bend: https://jend.leeeet.dev/read.txt?path=bend-osdev-crc@0.1.0.0/PROOF.bend&start_line=40&end_line=45 import Base import bend-osdev-word64@0.1.0.0/word64.bend as W import bend-osdev-bytes@0.1.0.0/bytes.bend as B import bend-osdev-crc@0.1.0.0/crc.bend as C def n64_split(xs: List<&2, U32>, +poly: W.W64, c: W.W64, ys: List<&2, U32>) -> {C.n64.raw(B.append(xs, ys), poly, c) == C.n64.raw(ys, poly, C.n64.raw(xs, poly, c)) : W.W64}: match xs: case Nil{}: {==} case Con{h, t}: n64_split(t, poly, C.n64.bits(8n, poly, W.W64.xor(c, W.W64.from_parts(U32.shln(U32.and(h, 255), 24n), 0))), ys) Uses (10): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 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.shln https://jend.leeeet.dev/definition.txt?path=bend-osdev-bytes@0.1.1.0/bytes.bend&name=append https://jend.leeeet.dev/definition.txt?path=bend-osdev-crc@0.1.0.0/crc.bend&name=n64.bits https://jend.leeeet.dev/definition.txt?path=bend-osdev-crc@0.1.0.0/crc.bend&name=n64.raw https://jend.leeeet.dev/definition.txt?path=bend-osdev-word64@0.1.1.0/word64.bend&name=W64 https://jend.leeeet.dev/definition.txt?path=bend-osdev-word64@0.1.1.0/word64.bend&name=W64.from_parts https://jend.leeeet.dev/definition.txt?path=bend-osdev-word64@0.1.1.0/word64.bend&name=W64.xor