Modify

Opened 21 months ago

#12111 new Bugs

use std placeholders in boost::bind in c++11

Reported by: anonymous Owned by: Peter Dimov
Milestone: To Be Determined Component: bind
Version: Boost 1.60.0 Severity: Problem
Keywords: Cc:

Description

Currently boost::bind imports its placeholders into the global namespace. Note that this can also happen if you do not just use boost bind at all, since multiple other boost libraries like boost::thread, boost::iostreams or boost::multi_index also include boost/bind.hpp in some way.

This clashes with std placeholders if people want to use them like they did previously with boost placeholders (in global namespace). Because _1 .. _N are now aliases to both the boost placeholders and the std placeholders.

To me it seems like the best way to fix this is to make boost bind use std placeholders when used with c++11 so that the boost::bind::placeholders namespace just becomes and alias for std::placeholders

Attachments (0)

Change History (0)

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The owner will remain Peter Dimov.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.