Argv.accepts: def of snap@1.4.0.0 Import: import snap@1.4.0.0/src/argv.bend as Argv Lines 36-44 of snap@1.4.0.0/src/argv.bend: https://jend.leeeet.dev/read.txt?path=snap@1.4.0.0/src/argv.bend&start_line=36&end_line=44 import Base # whether an argv can reach its program whole: it names a program, and no # argument holds NUL, which separates them on the wire and which no program # could be handed inside an argument anyway def accepts(argv: List<&2, String>) -> Bool: match argv: case []: False{} case +prog <> +args: Bool.and(Bool.not(String.is_empty(prog)), free_of.all(prog <> args, '\0')) Uses (8): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool.and https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool.not https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Char https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String.is_empty https://jend.leeeet.dev/definition.txt?path=snap@1.4.0.0/src/argv.bend&name=free_of.all