aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTaylor C. Richberger <taywee@gmx.com>2017-12-12 18:04:14 -0700
committerGitHub <noreply@github.com>2017-12-12 18:04:14 -0700
commit627cbaf92ce4c220b597f1b0217206903293a9ee (patch)
treee0da3153b9bd05538685b118c6af416c56670ca4
parentMerge pull request #54 from pavel-belikov/hidden-from-usage-or-description (diff)
parentUpdate args.hxx (diff)
downloadargs.hxx-627cbaf92ce4c220b597f1b0217206903293a9ee.tar.xz
Merge pull request #52 from maPaydar/patch-1
Adds ParseCLI overload to parse vector of string
-rw-r--r--args.hxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/args.hxx b/args.hxx
index f947de6..67f53eb 100644
--- a/args.hxx
+++ b/args.hxx
@@ -2662,6 +2662,11 @@ namespace args
const std::vector<std::string> args(argv + 1, argv + argc);
return ParseArgs(args) == std::end(args);
}
+
+ bool ParseCLI(const std::vector<std::string> &args)
+ {
+ return ParseArgs(args) == std::end(args);
+ }
};
inline Command::RaiiSubparser::RaiiSubparser(ArgumentParser &parser_, std::vector<std::string> args_)