I27 vector<string> doesn't parse

Reorder the `parse_value` functions so that the vector-specific
function can see all of the other specific parsers.
This commit is contained in:
Jarryd Beck 2016-07-05 08:29:20 +10:00
parent 21489b233d
commit abab8ce325

View File

@ -401,15 +401,6 @@ namespace cxxopts
}
}
template <typename T>
void
parse_value(const std::string& text, std::vector<T>& value)
{
T v;
parse_value(text, v);
value.push_back(v);
}
inline
void
parse_value(const std::string& /*text*/, bool& value)
@ -426,6 +417,15 @@ namespace cxxopts
value = text;
}
template <typename T>
void
parse_value(const std::string& text, std::vector<T>& value)
{
T v;
parse_value(text, v);
value.push_back(v);
}
template <typename T>
struct value_has_arg
{