def command_body_issues

cli@0.2.0.0 · cli.bend:2290

import cli@0.2.0.0/cli.bend as Cli
import Base

2290# has_pos: whether items has a positional.
2291def command_body_issues(+at: String, name: String, about: String,
2292    +items: List<&2, Item>, has_pos: Bool) -> List<&2, Problem>:
2293  List.concat(&2, Problem, [
2294    when_problem(Bool.and(String.is_empty(about),
2295      Bool.not(has_hidden(items))), NoHelp{at, name}),
2296    when_problem(Bool.and(has_pos, has_sub_item(items)), Mixed{at}),
2297    missing_refs(scope_group_rules(items), scope_groups(items), at),
2298    missing_refs(scope_groups(items), scope_group_rules(items), at),
2299    dead_required(needs_sub(items), items, at),
2300  ])

Uses (17)

Used by (2)