StorageTreeModel.fetch: def of stelliferous@0.0.2.0 Import: import stelliferous@0.0.2.0/proofs/storage_tree_model.bend as StorageTreeModel Lines 34-39 of stelliferous@0.0.2.0/proofs/storage_tree_model.bend: https://jend.leeeet.dev/read.txt?path=stelliferous@0.0.2.0/proofs/storage_tree_model.bend&start_line=34&end_line=39 import Base def fetch(-T: Data,tree: Tree,+n: U32,+i: U32) -> T: match tree: case Leaf{v}: v case Node{l,r}: Bool.pick(T,U32.is_lt(i,U32.shr(n)),fetch(T,l,U32.shr(n),i),fetch(T,r,U32.shr(n),U32.sub(i,U32.shr(n)))) Uses (6): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool.pick https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.is_lt https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.shr https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.sub https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/proofs/storage_tree_model.bend&name=Tree