30#ifndef _STLP_INTERNAL_FUNCTION_BASE_H
31#define _STLP_INTERNAL_FUNCTION_BASE_H
33#if defined (_STLP_CLASS_PARTIAL_SPECIALIZATION) && !defined (_STLP_TYPE_TRAITS_H)
39template <
class _Arg,
class _Result>
43#if !defined (__BORLANDC__) || (__BORLANDC__ < 0x580)
52template <
class _Arg1,
class _Arg2,
class _Result>
57#if !defined (__BORLANDC__) || (__BORLANDC__ < 0x580)
66 bool operator()(
const _Tp& __x,
const _Tp& __y)
const {
return __x == __y; }
71#if defined (_STLP_CLASS_PARTIAL_SPECIALIZATION)
79 bool operator()(
const _Tp& __x,
const _Tp& __y)
const {
return __x < __y; }
81#if defined (_STLP_USE_PARTIAL_SPEC_WORKAROUND) && !defined (_STLP_FUNCTION_TMPL_PARTIAL_ORDER)
82 void _M_swap_workaround(
less<_Tp>& __x) {}
86#if defined (_STLP_CLASS_PARTIAL_SPECIALIZATION)
89#if !defined (__BORLANDC__)
115 _Tp
operator()(
const _Tp& __x,
const _Tp& __y)
const {
return __x + __y; }
120 _Tp
operator()(
const _Tp& __x,
const _Tp& __y)
const {
return __x - __y; }
135 _Tp
operator()(
const _Tp& __x,
const _Tp& __y)
const {
return __x * __y; }
140template <
class _Pair>
142 const typename _Pair::first_type&
operator()(
const _Pair& __x)
const {
147template <
class _Pair>
149 const typename _Pair::second_type&
operator()(
const _Pair& __x)
const {
155template <
class _Arg1,
class _Arg2>
157 _Arg1
operator()(
const _Arg1& __x,
const _Arg2&)
const {
return __x; }
160template <
class _Arg1,
class _Arg2>
162 _Arg2
operator()(
const _Arg1&,
const _Arg2& __y)
const {
return __y; }
165#if defined (_STLP_MULTI_CONST_TEMPLATE_ARG_BUG)
167template <
class _Pair,
class _Whatever>
169struct __Select1st_hint :
public unary_function<_Pair, _Whatever> {
170 const _Whatever& operator () (
const _Pair& __x)
const {
return __x.first; }
172# define _STLP_SELECT1ST(__x,__y) _STLP_PRIV __Select1st_hint< __x, __y >
174# define _STLP_SELECT1ST(__x, __y) _STLP_PRIV _Select1st< __x >
182template <
class _Result,
class _Argument>
192template <
class _Result,
class _Arg1,
class _Arg2>
_STLP_MOVE_TO_PRIV_NAMESPACE plus< _Tp > __plus(_Tp *)
_Tp __identity_element(plus< _Tp >)
minus< _Tp > __minus(_Tp *)
_STLP_MOVE_TO_PRIV_NAMESPACE less< _Tp > __less(_Tp *)
equal_to< _Tp > __equal_to(_Tp *)
#define _STLP_MOVE_TO_STD_NAMESPACE
#define _STLP_BEGIN_NAMESPACE
#define _STLP_END_NAMESPACE
#define _STLP_MOVE_TO_PRIV_NAMESPACE
_Constant_binary_fun(const _Result &__v)
_Arg2 second_argument_type
const result_type & operator()(const _Arg1 &, const _Arg2 &) const
_Arg1 first_argument_type
const result_type & operator()(const _Argument &) const
_Constant_unary_fun(const result_type &__v)
const _Tp & operator()(const _Tp &__x) const
_Arg1 operator()(const _Arg1 &__x, const _Arg2 &) const
_Arg2 operator()(const _Arg1 &, const _Arg2 &__y) const
const _Pair::first_type & operator()(const _Pair &__x) const
const _Pair::second_type & operator()(const _Pair &__x) const
__bool2type< pod >::_Ret is_POD_type
__bool2type< trivial_destructor >::_Ret has_trivial_destructor
__bool2type< trivial_constructor >::_Ret has_trivial_default_constructor
__bool2type< trivial_copy >::_Ret has_trivial_copy_constructor
__bool2type< trivial_assign >::_Ret has_trivial_assignment_operator
_Arg1 first_argument_type
_Arg2 second_argument_type
bool operator()(const _Tp &__x, const _Tp &__y) const
bool operator()(const _Tp &__x, const _Tp &__y) const
_Tp operator()(const _Tp &__x, const _Tp &__y) const
_Tp operator()(const _Tp &__x, const _Tp &__y) const
_Tp operator()(const _Tp &__x, const _Tp &__y) const