MCPcopy Create free account
hub / github.com/docopt/docopt.cpp / Optional

Class Optional

docopt_private.h:295–305  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

293 };
294
295 class Optional : public BranchPattern {
296 public:
297 using BranchPattern::BranchPattern;
298
299 bool match(PatternList& left, std::vector<std::shared_ptr<LeafPattern>>& collected) const override {
300 for(auto const& pattern : fChildren) {
301 pattern->match(left, collected);
302 }
303 return true;
304 }
305 };
306
307 class OptionsShortcut : public Optional {
308 using Optional::Optional;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected