(command: &Command, prefix: Vec<String>, paths: &mut Vec<Vec<String>>)
| 13 | |
| 14 | fn visible_subcommand_paths(command: &Command) -> Vec<Vec<String>> { |
| 15 | fn collect(command: &Command, prefix: Vec<String>, paths: &mut Vec<Vec<String>>) { |
| 16 | for subcommand in command.get_subcommands().filter(|sub| !sub.is_hide_set()) { |
| 17 | let mut path = prefix.clone(); |
| 18 | path.push(subcommand.get_name().to_string()); |
| 19 | paths.push(path.clone()); |
| 20 | collect(subcommand, path, paths); |
| 21 | } |
| 22 | } |
| 23 | |
| 24 | let mut paths = Vec::new(); |
| 25 | collect(command, Vec::new(), &mut paths); |
no test coverage detected