1 #ifndef BOOST_BIND_HPP_INCLUDED
2 #define BOOST_BIND_HPP_INCLUDED
4 // MS compatible compilers support #pragma once
6 #if defined(_MSC_VER) && (_MSC_VER >= 1020)
10 // bind.hpp - binds function objects to arguments
12 // Copyright (c) 2009, 2015 Peter Dimov
14 // Distributed under the Boost Software License, Version 1.0.
15 // See accompanying file LICENSE_1_0.txt or copy at
16 // http://www.boost.org/LICENSE_1_0.txt
18 // See http://www.boost.org/libs/bind/bind.html for documentation.
20 // For backward compatibility, this header includes
21 // <boost/bind/bind.hpp> and then imports the placeholders _1, _2,
22 // _3, ... into the global namespace. Definitions in the global
23 // namespace are not a good practice and this use is deprecated.
24 // Please switch to including <boost/bind/bind.hpp> directly,
25 // adding the using directive locally where appropriate.
26 // Alternatively, the existing behavior may be preserved by defining
27 // the macro BOOST_BIND_GLOBAL_PLACEHOLDERS.
29 #include <boost/bind/bind.hpp>
30 #include <boost/config/pragma_message.hpp>
32 #ifndef BOOST_BIND_NO_PLACEHOLDERS
34 #if !defined(BOOST_BIND_GLOBAL_PLACEHOLDERS)
37 "The practice of declaring the Bind placeholders (_1, _2, ...) "
38 "in the global namespace is deprecated. Please use "
39 "<boost/bind/bind.hpp> + using namespace boost::placeholders, "
40 "or define BOOST_BIND_GLOBAL_PLACEHOLDERS to retain the current behavior."
45 #if defined(BOOST_CLANG)
46 # pragma clang diagnostic push
47 # if __has_warning("-Wheader-hygiene")
48 # pragma clang diagnostic ignored "-Wheader-hygiene"
52 using namespace boost::placeholders;
54 #if defined(BOOST_CLANG)
55 # pragma clang diagnostic pop
58 #endif // #ifndef BOOST_BIND_NO_PLACEHOLDERS
60 #endif // #ifndef BOOST_BIND_HPP_INCLUDED