def ascii

bend-collections-laws-crypto@1.0.0.0 · src/crypto/sha/core.bend:1143

import bend-collections-laws-crypto@1.0.0.0/src/crypto/sha/core.bend as Core
import Base

1143# ASCII convenience only; binary inputs use sha256 directly.
1144def ascii(s: String) -> List<&2, U32>:
1145  match s:
1146    case SNil{}:
1147      Nil{}
1148    case SCon{Chr{c}, t}:
1149      c <> ascii(t)

Uses (4)

Used by (1)