56 #ifndef _BACKWARD_BINDERS_H
57 #define _BACKWARD_BINDERS_H 1
60 #pragma GCC diagnostic push
61 #pragma GCC diagnostic ignored "-Wdeprecated-declarations"
63 namespace std _GLIBCXX_VISIBILITY(default)
65 _GLIBCXX_BEGIN_NAMESPACE_VERSION
107 template<
typename _Operation>
109 :
public unary_function<typename _Operation::second_argument_type,
110 typename _Operation::result_type>
114 typename _Operation::first_argument_type value;
118 const typename _Operation::first_argument_type& __y)
119 : op(__x), value(__y) { }
121 typename _Operation::result_type
122 operator()(
const typename _Operation::second_argument_type& __x)
const
123 {
return op(value, __x); }
127 typename _Operation::result_type
128 operator()(
typename _Operation::second_argument_type& __x)
const
129 {
return op(value, __x); }
130 } _GLIBCXX11_DEPRECATED_SUGGEST(
"std::bind");
133 template<
typename _Operation,
typename _Tp>
134 _GLIBCXX11_DEPRECATED_SUGGEST(
"std::bind")
136 bind1st(const _Operation& __fn, const _Tp& __x)
138 typedef typename _Operation::first_argument_type _Arg1_type;
143 template<
typename _Operation>
146 typename _Operation::result_type>
150 typename _Operation::second_argument_type value;
154 const typename _Operation::second_argument_type& __y)
155 : op(__x), value(__y) { }
157 typename _Operation::result_type
158 operator()(
const typename _Operation::first_argument_type& __x)
const
159 {
return op(__x, value); }
163 typename _Operation::result_type
164 operator()(
typename _Operation::first_argument_type& __x)
const
165 {
return op(__x, value); }
166 } _GLIBCXX11_DEPRECATED_SUGGEST(
"std::bind");
169 template<
typename _Operation,
typename _Tp>
170 _GLIBCXX11_DEPRECATED_SUGGEST(
"std::bind")
172 bind2nd(const _Operation& __fn, const _Tp& __x)
174 typedef typename _Operation::second_argument_type _Arg2_type;
179 _GLIBCXX_END_NAMESPACE_VERSION
182 #pragma GCC diagnostic pop
binder2nd< _Operation > bind2nd(const _Operation &__fn, const _Tp &__x)
One of the binder functors.
binder1st< _Operation > bind1st(const _Operation &__fn, const _Tp &__x)
One of the binder functors.
ISO C++ entities toplevel namespace is std.
One of the binder functors.
One of the binder functors.