namespace Msp {
-GetOpt::GetOpt():
- help(false)
+GetOpt::GetOpt()
{
add_option("help", help, NO_ARG).set_help("Displays this help");
}
if((s!=0 && (*i)->get_short()==s) || (*i)->get_long()==l)
{
delete *i;
- opts.erase(i++);
+ i = opts.erase(i);
}
else
++i;
bool any_short = any_of(opts.begin(), opts.end(), [](const OptionImpl *o){ return o->get_short(); });
string::size_type maxw = 0;
- list<string> switches;
+ vector<string> switches;
for(const OptionImpl *o: opts)
{
string swtch;
maxw = max(maxw, swtch.size());
}
- list<string> pargs;
+ vector<string> pargs;
for(const ArgumentImpl *a: args)
{
string parg = format("<%s>", a->get_name());
shrt(s),
lng(l),
arg_type(a),
- seen_count(0),
- ext_seen_count(0),
- metavar("ARG"),
store(t.clone())
{ }