diff options
| author | Petr Machata <[email protected]> | 2010-09-24 18:41:40 +0200 |
|---|---|---|
| committer | Petr Machata <[email protected]> | 2010-09-24 18:41:40 +0200 |
| commit | e966f19d486f4874faced1baac15307e61010b4b (patch) | |
| tree | 790f8043ab41742b2e06bf9a98ad9e8430aea08d /dwarflint/option.hh | |
| parent | 2e8236968ede6077d4d75782bd02c6c470c3f6b9 (diff) | |
dwarflint: --list-checks now lists options associated with check passes
Diffstat (limited to 'dwarflint/option.hh')
| -rw-r--r-- | dwarflint/option.hh | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/dwarflint/option.hh b/dwarflint/option.hh index 6bde308c..15a9bf46 100644 --- a/dwarflint/option.hh +++ b/dwarflint/option.hh @@ -48,10 +48,10 @@ public: option_i const *getopt (int key) const; argp build_argp (bool toplev = false) const; void add (option_i *opt); - bool empty () const - { - return std::map<int, option_i *>::empty (); - } + using std::map<int, option_i *>::empty; + using std::map<int, option_i *>::begin; + using std::map<int, option_i *>::end; + using std::map<int, option_i *>::const_iterator; }; // Wrapper of argp parsing. While in general argp does a decent job, @@ -97,6 +97,7 @@ public: virtual argp_option const &build_option () const = 0; virtual error_t parse_opt (char *arg, argp_state *state) = 0; virtual int key () const = 0; + virtual std::string format () const = 0; virtual ~option_i () {} }; @@ -131,6 +132,8 @@ public: { return _m_opt.key; } + + std::string format () const; }; template<class arg_type> |
