Cli.problem_line: def of cli@0.2.0.0 Import: import cli@0.2.0.0/cli.bend as Cli Lines 6091-6126 of cli@0.2.0.0/cli.bend: https://jend.leeeet.dev/read.txt?path=cli@0.2.0.0/cli.bend&start_line=6091&end_line=6126 import Base def problem_line(p: Problem) -> String: match p: case BadUsage{at, usage, col}: String.concat([" ", at, ": usage '", usage, "' is invalid at column ", Nat.show((col + 1n : Nat))]) case BadName{at, name}: String.concat([" ", at, ": '", name, "' is not a valid name"]) case Dup{at, name}: String.concat([" ", at, ": '", name, "' is declared more than once"]) case Reserved{at, name}: String.concat([" ", at, ": '", name, "' is reserved"]) case Misplaced{at, attr}: String.concat([" ", at, ": '", attr, "' is not allowed here"]) case NoHelp{at, what}: String.concat([" ", at, ": '", what, "' has no help text"]) case BadDefault{at, id, value}: String.concat([" ", at, ": '", id, "' cannot have the default '", value, "'"]) case BadRef{at, id}: String.concat([" ", at, ": '", id, "' is an unknown id or an unused or empty group"]) case BadPositional{at, id, why}: String.concat([" ", at, ": positional '", id, "': ", why]) case Mixed{at}: String.concat([" ", at, ": has both positionals and subcommands"]) case BadChoices{at, id}: String.concat([" ", at, ": one_of for '", id, "' is empty or repeats a value"]) case BadChoice{at, id, value}: String.concat([" ", at, ": '", id, "' cannot have the choice '", value, "'"]) case NeedBare{at, id}: String.concat([" ", at, ": '", id, "' needs [=] and bare() together, with no short"]) case DecodeBug{at, msg}: String.concat([" ", at, ": decoder bug: ", msg]) Uses (7): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List 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=Nat.show https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String.concat https://jend.leeeet.dev/definition.txt?path=cli@0.2.0.0/cli.bend&name=Problem