diff --git a/src/cxxopts.hpp b/src/cxxopts.hpp index 0d7ae1e..3ff24db 100644 --- a/src/cxxopts.hpp +++ b/src/cxxopts.hpp @@ -54,7 +54,7 @@ namespace cxxopts return icu::UnicodeString::fromUTF8(s); } - class UnicodeStringIterator : public + class UnicodeStringIterator : public std::iterator { public: @@ -244,7 +244,7 @@ namespace cxxopts virtual std::string get_default_value() const = 0; - virtual std::string + virtual std::string get_implicit_value() const = 0; virtual std::shared_ptr @@ -410,7 +410,7 @@ namespace cxxopts //so that we can write --long=yes explicitly value = true; } - + inline void parse_value(const std::string& text, std::string& value) @@ -452,7 +452,7 @@ namespace cxxopts { parse_value(m_implicit_value, *m_store); } - else + else { parse_value(text, *m_store); } @@ -484,14 +484,14 @@ namespace cxxopts virtual std::shared_ptr default_value(const std::string& value){ - m_default = true; + m_default = true; m_default_value = value; return shared_from_this(); } virtual std::shared_ptr implicit_value(const std::string& value){ - m_implicit = true; + m_implicit = true; m_implicit_value = value; return shared_from_this(); } @@ -932,7 +932,7 @@ OptionAdder::operator() const auto& s = result[2]; const auto& l = result[3]; - m_options.add_option(m_group, s.str(), l.str(), desc, value, + m_options.add_option(m_group, s.str(), l.str(), desc, value, std::move(arg_help)); return *this; @@ -969,8 +969,8 @@ Options::checked_parse_arg { throw missing_argument_exception(name); } - } - else + } + else { if (argv[current + 1][0] == '-' && value->value().has_implicit()) { @@ -1243,7 +1243,7 @@ Options::help_one_group(const std::string& g) const } else { - result += toLocalString(std::string(longest + OPTION_DESC_GAP - + result += toLocalString(std::string(longest + OPTION_DESC_GAP - stringLength(fiter->first), ' ')); }