1
0
mirror of https://github.com/CLIUtils/CLI11.git synced 2025-04-29 12:13:52 +00:00

Fix some text from last PR

This commit is contained in:
Henry Fredrick Schreiner 2019-02-01 09:58:05 +01:00
parent d3c3a4c58f
commit 23802ea123

View File

@ -151,7 +151,7 @@ struct NonexistentPathValidator : public Validator {
}
};
/// validate the given string is a legal ipv4 address
/// Validate the given string is a legal ipv4 address
struct IPV4Validator : public Validator {
IPV4Validator() {
tname = "IPV4";
@ -176,10 +176,10 @@ struct IPV4Validator : public Validator {
}
};
/// validate the argument is a number and equal greater then 0
/// Validate the argument is a number and equal greater then 0
struct PositiveNumber : public Validator {
PositiveNumber() {
tname = "positive number";
tname = "POSITIVE";
func = [](const std::string &number_str) {
int number;
if(!detail::lexical_cast(number_str, number)) {
@ -209,10 +209,10 @@ const detail::ExistingPathValidator ExistingPath;
/// Check for an non-existing path
const detail::NonexistentPathValidator NonexistentPath;
/// Check for an existing path
/// Check for an IP4 address
const detail::IPV4Validator ValidIPV4;
/// Check for an non-existing path
/// Check for a positive number
const detail::PositiveNumber PositiveNumber;
/// Produce a range (factory). Min and max are inclusive.
@ -241,10 +241,10 @@ struct Range : public Validator {
};
namespace detail {
/// split a string into a program name and command line arguments
/// Split a string into a program name and command line arguments
/// the string is assumed to contain a file name followed by other arguments
/// the return value contains is a pair with the first argument containing the program name and the second everything
/// else
/// else.
inline std::pair<std::string, std::string> split_program_name(std::string commandline) {
// try to determine the programName
std::pair<std::string, std::string> vals;