Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r62236 - in trunk/boost/program_options: . detail
From: ghost_at_[hidden]
Date: 2010-05-26 06:40:36


Author: vladimir_prus
Date: 2010-05-26 06:40:34 EDT (Wed, 26 May 2010)
New Revision: 62236
URL: http://svn.boost.org/trac/boost/changeset/62236

Log:
Fix -Wshadow warnings. Closes #4015.
Patch from Tatu Kilappa.

Text files modified:
   trunk/boost/program_options/detail/parsers.hpp | 8 ++++----
   trunk/boost/program_options/detail/value_semantic.hpp | 6 +++---
   trunk/boost/program_options/errors.hpp | 6 +++---
   trunk/boost/program_options/option.hpp | 8 ++++----
   trunk/boost/program_options/options_description.hpp | 2 +-
   trunk/boost/program_options/parsers.hpp | 4 ++--
   trunk/boost/program_options/variables_map.hpp | 4 ++--
   7 files changed, 19 insertions(+), 19 deletions(-)

Modified: trunk/boost/program_options/detail/parsers.hpp
==============================================================================
--- trunk/boost/program_options/detail/parsers.hpp (original)
+++ trunk/boost/program_options/detail/parsers.hpp 2010-05-26 06:40:34 EDT (Wed, 26 May 2010)
@@ -29,8 +29,8 @@
     template<class charT>
     basic_command_line_parser<charT>::
     basic_command_line_parser(const std::vector<
- std::basic_string<charT> >& args)
- : detail::cmdline(to_internal(args))
+ std::basic_string<charT> >& xargs)
+ : detail::cmdline(to_internal(xargs))
     {}
 
 
@@ -64,9 +64,9 @@
 
     template<class charT>
     basic_command_line_parser<charT>&
- basic_command_line_parser<charT>::style(int style)
+ basic_command_line_parser<charT>::style(int xstyle)
     {
- detail::cmdline::style(style);
+ detail::cmdline::style(xstyle);
         return *this;
     }
 

Modified: trunk/boost/program_options/detail/value_semantic.hpp
==============================================================================
--- trunk/boost/program_options/detail/value_semantic.hpp (original)
+++ trunk/boost/program_options/detail/value_semantic.hpp 2010-05-26 06:40:34 EDT (Wed, 26 May 2010)
@@ -143,9 +143,9 @@
                    a validator for class T, we use it even
                    when parsing vector<T>. */
                 boost::any a;
- std::vector<std::basic_string<charT> > v;
- v.push_back(s[i]);
- validate(a, v, (T*)0, 0);
+ std::vector<std::basic_string<charT> > cv;
+ cv.push_back(s[i]);
+ validate(a, cv, (T*)0, 0);
                 tv->push_back(boost::any_cast<T>(a));
             }
             catch(const bad_lexical_cast& /*e*/) {

Modified: trunk/boost/program_options/errors.hpp
==============================================================================
--- trunk/boost/program_options/errors.hpp (original)
+++ trunk/boost/program_options/errors.hpp 2010-05-26 06:40:34 EDT (Wed, 26 May 2010)
@@ -20,7 +20,7 @@
     /** Base class for all errors in the library. */
     class BOOST_PROGRAM_OPTIONS_DECL error : public std::logic_error {
     public:
- error(const std::string& what) : std::logic_error(what) {}
+ error(const std::string& xwhat) : std::logic_error(xwhat) {}
     };
 
     class BOOST_PROGRAM_OPTIONS_DECL invalid_syntax : public error {
@@ -78,9 +78,9 @@
     class BOOST_PROGRAM_OPTIONS_DECL ambiguous_option : public error {
     public:
         ambiguous_option(const std::string& name,
- const std::vector<std::string>& alternatives)
+ const std::vector<std::string>& xalternatives)
         : error(std::string("ambiguous option ").append(name))
- , m_alternatives(alternatives)
+ , m_alternatives(xalternatives)
         , m_option_name(name)
         {}
 

Modified: trunk/boost/program_options/option.hpp
==============================================================================
--- trunk/boost/program_options/option.hpp (original)
+++ trunk/boost/program_options/option.hpp 2010-05-26 06:40:34 EDT (Wed, 26 May 2010)
@@ -28,10 +28,10 @@
         , unregistered(false)
         , case_insensitive(false)
         {}
- basic_option(const std::string& string_key,
- const std::vector< std::string> &value)
- : string_key(string_key)
- , value(value)
+ basic_option(const std::string& xstring_key,
+ const std::vector< std::string> &xvalue)
+ : string_key(xstring_key)
+ , value(xvalue)
         , unregistered(false)
         , case_insensitive(false)
         {}

Modified: trunk/boost/program_options/options_description.hpp
==============================================================================
--- trunk/boost/program_options/options_description.hpp (original)
+++ trunk/boost/program_options/options_description.hpp 2010-05-26 06:40:34 EDT (Wed, 26 May 2010)
@@ -247,7 +247,7 @@
     /** Class thrown when duplicate option description is found. */
     class BOOST_PROGRAM_OPTIONS_DECL duplicate_option_error : public error {
     public:
- duplicate_option_error(const std::string& what) : error(what) {}
+ duplicate_option_error(const std::string& xwhat) : error(xwhat) {}
     };
 }}
 

Modified: trunk/boost/program_options/parsers.hpp
==============================================================================
--- trunk/boost/program_options/parsers.hpp (original)
+++ trunk/boost/program_options/parsers.hpp 2010-05-26 06:40:34 EDT (Wed, 26 May 2010)
@@ -31,8 +31,8 @@
     template<class charT>
     class basic_parsed_options {
     public:
- explicit basic_parsed_options(const options_description* description)
- : description(description) {}
+ explicit basic_parsed_options(const options_description* xdescription)
+ : description(xdescription) {}
         /** Options found in the source. */
         std::vector< basic_option<charT> > options;
         /** Options description that was used for parsing.

Modified: trunk/boost/program_options/variables_map.hpp
==============================================================================
--- trunk/boost/program_options/variables_map.hpp (original)
+++ trunk/boost/program_options/variables_map.hpp 2010-05-26 06:40:34 EDT (Wed, 26 May 2010)
@@ -53,8 +53,8 @@
     class BOOST_PROGRAM_OPTIONS_DECL variable_value {
     public:
         variable_value() : m_defaulted(false) {}
- variable_value(const boost::any& v, bool defaulted)
- : v(v), m_defaulted(defaulted)
+ variable_value(const boost::any& xv, bool xdefaulted)
+ : v(xv), m_defaulted(xdefaulted)
         {}
 
         /** If stored value if of type T, returns that value. Otherwise,


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk