mirror of
https://github.com/boostorg/program_options.git
synced 2026-01-19 04:22:15 +00:00
Explicitly-qualify the use of boost::bind.
It appears that MSVC 10 puts tr1's bind into std namespace, which clases with boost::bind thanks to ADL. Closes #3072. Patch from Richard Webb. [SVN r53700]
This commit is contained in:
@@ -196,24 +196,24 @@ namespace boost { namespace program_options { namespace detail {
|
||||
|
||||
if (m_additional_parser)
|
||||
style_parsers.push_back(
|
||||
bind(&cmdline::handle_additional_parser, this, _1));
|
||||
boost::bind(&cmdline::handle_additional_parser, this, _1));
|
||||
|
||||
if (m_style & allow_long)
|
||||
style_parsers.push_back(
|
||||
bind(&cmdline::parse_long_option, this, _1));
|
||||
boost::bind(&cmdline::parse_long_option, this, _1));
|
||||
|
||||
if ((m_style & allow_long_disguise))
|
||||
style_parsers.push_back(
|
||||
bind(&cmdline::parse_disguised_long_option, this, _1));
|
||||
boost::bind(&cmdline::parse_disguised_long_option, this, _1));
|
||||
|
||||
if ((m_style & allow_short) && (m_style & allow_dash_for_short))
|
||||
style_parsers.push_back(
|
||||
bind(&cmdline::parse_short_option, this, _1));
|
||||
boost::bind(&cmdline::parse_short_option, this, _1));
|
||||
|
||||
if ((m_style & allow_short) && (m_style & allow_slash_for_short))
|
||||
style_parsers.push_back(bind(&cmdline::parse_dos_option, this, _1));
|
||||
style_parsers.push_back(boost::bind(&cmdline::parse_dos_option, this, _1));
|
||||
|
||||
style_parsers.push_back(bind(&cmdline::parse_terminator, this, _1));
|
||||
style_parsers.push_back(boost::bind(&cmdline::parse_terminator, this, _1));
|
||||
|
||||
vector<option> result;
|
||||
while(!args.empty())
|
||||
|
||||
@@ -71,12 +71,12 @@ namespace boost { namespace program_options {
|
||||
|
||||
std::transform(opt.value.begin(), opt.value.end(),
|
||||
back_inserter(result.value),
|
||||
bind(from_utf8, _1));
|
||||
boost::bind(from_utf8, _1));
|
||||
|
||||
std::transform(opt.original_tokens.begin(),
|
||||
opt.original_tokens.end(),
|
||||
back_inserter(result.original_tokens),
|
||||
bind(from_utf8, _1));
|
||||
boost::bind(from_utf8, _1));
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user