From c305768ed8f947f99621e7c313ccb5ef8e5ceb86 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sun, 14 Jun 2015 14:14:27 -0400 Subject: [PATCH] CLI2: Now relies on Lexer::Type::separator, rather than literal "--". --- src/CLI2.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/CLI2.cpp b/src/CLI2.cpp index b409a4211..50e65a3b2 100644 --- a/src/CLI2.cpp +++ b/src/CLI2.cpp @@ -816,6 +816,7 @@ void CLI2::addArg (const std::string& arg) } } */ + //////////////////////////////////////////////////////////////////////////////// void CLI2::aliasExpansion () { @@ -832,7 +833,7 @@ void CLI2::aliasExpansion () for (auto& i : _args) { raw = i.attribute ("raw"); - if (raw == "--") + if (i._lextype == Lexer::Type::separator) terminated = true; if (! terminated) @@ -878,10 +879,10 @@ void CLI2::findOverrides () for (auto& a : _args) { - raw = a.attribute ("raw"); - if (raw == "--") + if (a._lextype == Lexer::Type::separator) break; + raw = a.attribute ("raw"); if (raw.length () > 3 && raw.find ("rc:") == 0) {