Cli.code_bytes: def of cli@0.2.0.0 Import: import cli@0.2.0.0/cli.bend as Cli Lines 8007-8014 of cli@0.2.0.0/cli.bend: https://jend.leeeet.dev/read.txt?path=cli@0.2.0.0/cli.bend&start_line=8007&end_line=8014 import Base def code_bytes(ascii: Bool, escape: Bool, scalar: Bool, +x: U32) -> List<&2, U32>: match ascii escape scalar: case True{} _ _: [x] case False{} True{} _: [(x - 56320 : U32)] case False{} False{} True{}: utf8_bytes(U32.is_lt(x, 2048), U32.is_lt(x, 65536), x) case False{} False{} False{}: [239, 191, 189] Uses (6): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.is_lt https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.sub https://jend.leeeet.dev/definition.txt?path=cli@0.2.0.0/cli.bend&name=utf8_bytes