def fit_words
import bendtorch-core@0.1.0.0/src/shape/core.bend as Coreimport Base
417def fit_words(dims: List<&2, U32>, values: List<&2, U32>) -> Bool:
418 match dims values:
419 case Nil{} Nil{}:
420 True{}
421 case dh <> dt vh <> vt:
422 Bool.and(Nat.is_lt(U32.to_nat(vh), U32.to_nat(dh)), fit_words(dt, vt))
423 case Nil{} vh <> vt:
424 False{}
425 case dh <> dt Nil{}:
426 False{}
Uses (6)
Used by (16)
- bendtorch-core@0.1.0.0/src/shape/core:flatten_checked.ranked
- bendtorch-core@0.1.0.0/src/shape/boundary_proofs:fit_words_false
- bendtorch-core@0.1.0.0/src/shape/boundary_proofs:fit_words_true
- bendtorch-core@0.1.0.0/src/shape/core:flatten_checked.fits
- bendtorch-core@0.1.0.0/src/shape/core:projection_checked.fits
- …