def lc.tab.path

bend-osdev-cipher-core@0.1.0.0 · cipher_core.bend:300

import bend-osdev-cipher-core@0.1.0.0/cipher_core.bend as CipherCore
import Base

300# the bits of i (below 2^d) that pick its entry, most significant first
301def lc.tab.path(d: Nat, +i: U32) -> List<&2, Bool>:
302  match d:
303    case 0n:
304      Nil{}
305    case 1n+(+p):
306      Con{U32.is_eq(lc.bit(i, p), 1), lc.tab.path(p, i)}

Uses (6)

Used by (1)