def from_string

bend-kit-bytes@0.3.3.0 · bytes.bend:316

import bend-kit-bytes@0.3.3.0/bytes.bend as Bytes
import Base

316# A byte string (one Char per octet, as Wire and Http use) to Bytes. Each Char keeps its low 8 bits.
317def from_string(+s: String) -> Bytes:
318  +n = count(s, 0)
319  Bytes{n, from.go(s, alloc(n), 0, 0)}

Uses (5)

Used by (72)