def ASet.J
import bend-ml-tensor-array@0.1.19.0/main.bend as BendMlTensorArrayimport Base
2034# the masked index and the first branch, as Array.swap.at and Array.get.at compute them from a size n
2035def ASet.J(+i: U32, +n: U32) -> U32:
2036 U32.and(i, U32.sub(n, 1))