Cli.parse_long_prefixed: def of cli@0.2.0.0 Import: import cli@0.2.0.0/cli.bend as Cli Lines 1357-1369 of cli@0.2.0.0/cli.bend: https://jend.leeeet.dev/read.txt?path=cli@0.2.0.0/cli.bend&start_line=1357&end_line=1369 import Base # A long name after "--[no-]" or "--", at column start. def parse_long_prefixed(s: String, short: String, repeat: Bool, +start: Nat) -> Usage: match s: case SCon{Chr{45}, SCon{Chr{45}, SCon{Chr{91}, SCon{Chr{110}, SCon{Chr{111}, SCon{Chr{45}, SCon{Chr{93}, rest}}}}}}}: finish_long(scan_name(rest, Nat.add(start, 7n), "", True{}, Nat.add(start, 7n)), short, repeat, True{}) case SCon{Chr{45}, SCon{Chr{45}, rest}}: finish_long(scan_name(rest, Nat.add(start, 2n), "", True{}, Nat.add(start, 2n)), short, repeat, False{}) case _: Invalid{start} Uses (11): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Char https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.add https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Word.Con https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Word.Nil https://jend.leeeet.dev/definition.txt?path=cli@0.2.0.0/cli.bend&name=Usage https://jend.leeeet.dev/definition.txt?path=cli@0.2.0.0/cli.bend&name=finish_long https://jend.leeeet.dev/definition.txt?path=cli@0.2.0.0/cli.bend&name=scan_name