def sub_at

cli@0.2.0.0 · cli.bend:7633

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

7633# The subcommand at path, from found on.
7634def sub_at(path: List<&2, String>, items: List<&2, Item>,
7635    found: Maybe<&2, SubFound>) -> Maybe<&2, SubFound>:
7636  match path:
7637    case Nil{}: found
7638    case name <> tail:
7639      +next = find_sub(items, name)
7640      sub_at(tail, sub_items(next), next)

Uses (7)

Used by (1)