| 8093 | inline std::string Formatter::make_option_desc(const Option *opt) const { return opt->get_description(); } |
| 8094 | |
| 8095 | inline std::string Formatter::make_option_usage(const Option *opt) const { |
| 8096 | // Note that these are positionals usages |
| 8097 | std::stringstream out; |
| 8098 | out << make_option_name(opt, true); |
| 8099 | if (opt->get_expected_max() >= detail::expected_max_vector_size) |
| 8100 | out << "..."; |
| 8101 | else if (opt->get_expected_max() > 1) |
| 8102 | out << "(" << opt->get_expected() << "x)"; |
| 8103 | |
| 8104 | return opt->get_required() ? out.str() : "[" + out.str() + "]"; |
| 8105 | } |
| 8106 | |
| 8107 | } // namespace CLI |
nothing calls this directly
no test coverage detected