aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTaylor C. Richberger <Taywee@gmx.com>2016-06-02 19:16:31 -0600
committerTaylor C. Richberger <Taywee@gmx.com>2016-06-02 19:16:31 -0600
commit48a7f394103eea11310d939b51a3167787297f7a (patch)
treee61751ab69927354cc24cefc8e8cbaf151366ab2
parentallow set use (diff)
downloadargs.hxx-48a7f394103eea11310d939b51a3167787297f7a.tar.xz
fixed problem hopefully
-rw-r--r--args.hxx12
1 files changed, 6 insertions, 6 deletions
diff --git a/args.hxx b/args.hxx
index dcfa235..ac9ccfc 100644
--- a/args.hxx
+++ b/args.hxx
@@ -1154,16 +1154,16 @@ namespace args
{
if (ValueFlagBase *argbase = dynamic_cast<ValueFlagBase *>(base))
{
- const std::string arg(++argit, std::end(argchunk));
- if (!arg.empty())
+ const std::string value(++argit, std::end(argchunk));
+ if (!value.empty())
{
if (allowJoinedShortValue)
{
- argbase->ParseValue(arg);
+ argbase->ParseValue(value);
} else
{
std::ostringstream problem;
- problem << "Flag '" << *argit << "' was passed a joined argument, but these are disallowed";
+ problem << "Flag '" << arg << "' was passed a joined argument, but these are disallowed";
throw ParseError(problem.str());
}
} else
@@ -1172,7 +1172,7 @@ namespace args
if (it == end)
{
std::ostringstream problem;
- problem << "Flag '" << *argit << "' requires an argument but received none";
+ problem << "Flag '" << arg << "' requires an argument but received none";
throw ParseError(problem.str());
}
@@ -1182,7 +1182,7 @@ namespace args
} else
{
std::ostringstream problem;
- problem << "Flag '" << *argit << "' was passed a separate argument, but these are disallowed";
+ problem << "Flag '" << arg << "' was passed a separate argument, but these are disallowed";
throw ParseError(problem.str());
}
}