LAWS.swap_old: law of lawful-arrays@0.1.0.0 Import: import lawful-arrays@0.1.0.0/LAWS.bend as LAWS Lines 136-144 of lawful-arrays@0.1.0.0/LAWS.bend: https://jend.leeeet.dev/read.txt?path=lawful-arrays@0.1.0.0/LAWS.bend&start_line=136&end_line=144 import Base import lawful-arrays@0.1.0.0/defs.bend as D law swap_old: for -T: Data for a: Array for d: Nat for i: U32 for v: T for hf: {D.full(T, a, d) == True{} : Bool} for hd: {Nat.is_lt(d, 32n) == True{} : Bool} {Some{Pair.snd(Array, T, Array.swap(T, a, i, v))} == List.get(&2, T, D.view(T, a), D.slot(i, d)) : Maybe<&2, T>} Uses (14): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Array https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Array.swap https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List.get https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Maybe https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.is_lt https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Pair.snd https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=lawful-arrays@0.1.0.0/PROOF.bend&name=swap_old.go https://jend.leeeet.dev/definition.txt?path=lawful-arrays@0.1.0.0/defs.bend&name=full https://jend.leeeet.dev/definition.txt?path=lawful-arrays@0.1.0.0/defs.bend&name=slot https://jend.leeeet.dev/definition.txt?path=lawful-arrays@0.1.0.0/defs.bend&name=view https://jend.leeeet.dev/definition.txt?path=lawful-arrays@0.1.0.0/proof_tree.bend&name=mirror