diff options
Diffstat (limited to 'bdep/utility.hxx')
-rw-r--r-- | bdep/utility.hxx | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/bdep/utility.hxx b/bdep/utility.hxx index d5e98c8..8e3ca3c 100644 --- a/bdep/utility.hxx +++ b/bdep/utility.hxx @@ -303,6 +303,26 @@ namespace bdep return r; } + namespace cli + { + class vector_group_scanner: public group_scanner + { + public: + explicit + vector_group_scanner (const std::vector<std::string>& args) + : group_scanner (scan_), scan_ (args) {} + + void + skip_group () + { + for (scanner& g (group ()); g.more (); g.skip ()) ; + } + + private: + vector_scanner scan_; + }; + } + // Verify that a string is a valid UTF-8 byte sequence encoding only the // graphic Unicode codepoints. Issue diagnostics (including a suggestion to // use option opt, if specified) and fail if that's not the case. |