Cli.utf8_lead: def of cli@0.2.0.0 Import: import cli@0.2.0.0/cli.bend as Cli Lines 7916-7922 of cli@0.2.0.0/cli.bend: https://jend.leeeet.dev/read.txt?path=cli@0.2.0.0/cli.bend&start_line=7916&end_line=7922 import Base def utf8_lead(+b: U32) -> Utf8Lead: Bool.pick(Utf8Lead, U32.is_lt(b, 194), NotLead{}, Bool.pick(Utf8Lead, U32.is_lt(b, 224), Utf8Lead{1n, (b - 192 : U32), 128}, Bool.pick(Utf8Lead, U32.is_lt(b, 240), Utf8Lead{2n, (b - 224 : U32), 2048}, Bool.pick(Utf8Lead, U32.is_lt(b, 245), Utf8Lead{3n, (b - 240 : U32), 65536}, NotLead{})))) Uses (5): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool.pick 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=Utf8Lead