57 #ifndef _BACKWARD_BINDERS_H
58 #define _BACKWARD_BINDERS_H 1
60 _GLIBCXX_BEGIN_NAMESPACE(
std)
96 template<typename _Operation>
103 typename _Operation::first_argument_type value;
107 const typename _Operation::first_argument_type& __y)
108 : op(__x), value(__y) { }
110 typename _Operation::result_type
111 operator()(
const typename _Operation::second_argument_type& __x)
const
112 {
return op(value, __x); }
116 typename _Operation::result_type
117 operator()(
typename _Operation::second_argument_type& __x)
const
118 {
return op(value, __x); }
119 } _GLIBCXX_DEPRECATED_ATTR;
122 template<
typename _Operation,
typename _Tp>
124 bind1st(
const _Operation& __fn,
const _Tp& __x)
126 typedef typename _Operation::first_argument_type _Arg1_type;
131 template<
typename _Operation>
134 typename _Operation::result_type>
138 typename _Operation::second_argument_type value;
142 const typename _Operation::second_argument_type& __y)
143 : op(__x), value(__y) { }
145 typename _Operation::result_type
146 operator()(
const typename _Operation::first_argument_type& __x)
const
147 {
return op(__x, value); }
151 typename _Operation::result_type
152 operator()(
typename _Operation::first_argument_type& __x)
const
153 {
return op(__x, value); }
154 } _GLIBCXX_DEPRECATED_ATTR;
157 template<
typename _Operation,
typename _Tp>
159 bind2nd(
const _Operation& __fn,
const _Tp& __x)
161 typedef typename _Operation::second_argument_type _Arg2_type;
166 _GLIBCXX_END_NAMESPACE
One of the binder functors.
ISO C++ entities toplevel namespace is std.
binder1st< _Operation > bind1st(const _Operation &__fn, const _Tp &__x)
One of the binder functors.
One of the binder functors.
binder2nd< _Operation > bind2nd(const _Operation &__fn, const _Tp &__x)
One of the binder functors.
_Operation::result_type result_type
result_type is the return type