TensorCursor.step: def of stelliferous@0.0.2.0 Import: import stelliferous@0.0.2.0/tensor_cursor.bend as TensorCursor Lines 53-58 of stelliferous@0.0.2.0/tensor_cursor.bend: https://jend.leeeet.dev/read.txt?path=stelliferous@0.0.2.0/tensor_cursor.bend&start_line=53&end_line=58 import Base def step(~Rest: Data,~next: Rest -> U32 -> Rest & U32,level: Level,address: U32) -> Level & U32: Level{axis,rest} = level match axis: case Axis{extent,0n,stride,rewind}: (Level{Axis{extent,0n,stride,rewind},rest},address) case Axis{+extent,1n,stride,+rewind}: reset(~Rest,extent,stride,rewind,next(rest,(address - rewind : U32))) case Axis{extent,1n+1n+remaining,+stride,rewind}: (Level{Axis{extent,1n+remaining,stride,rewind},rest},(address + stride : U32)) Uses (9): 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.sub https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/tensor_cursor.bend&name=Axis https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/tensor_cursor.bend&name=Level https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/tensor_cursor.bend&name=reset