/
usr
/
include
/
boost
/
icl
/
type_traits
/
/usr/include/boost/icl/type_traits
mkdir
upload
Name
Size
Mode
Actions
absorbs_identities.hpp
815
0644
edit
dl
rm
adds_inversely.hpp
998
0644
edit
dl
rm
codomain_type_of.hpp
1837
0644
edit
dl
rm
difference.hpp
701
0644
edit
dl
rm
difference_type_of.hpp
3343
0644
edit
dl
rm
domain_type_of.hpp
1442
0644
edit
dl
rm
element_type_of.hpp
2959
0644
edit
dl
rm
has_inverse.hpp
1041
0644
edit
dl
rm
has_set_semantics.hpp
1328
0644
edit
dl
rm
identity_element.hpp
1093
0644
edit
dl
rm
infinity.hpp
4499
0644
edit
dl
rm
interval_type_default.hpp
2095
0644
edit
dl
rm
interval_type_of.hpp
1467
0644
edit
dl
rm
is_associative_element_container.hpp
1139
0644
edit
dl
rm
is_asymmetric_interval.hpp
1819
0644
edit
dl
rm
is_combinable.hpp
18014
0644
edit
dl
rm
is_concept_equivalent.hpp
1345
0644
edit
dl
rm
is_container.hpp
1952
0644
edit
dl
rm
is_continuous.hpp
933
0644
edit
dl
rm
is_continuous_interval.hpp
866
0644
edit
dl
rm
is_discrete.hpp
2109
0644
edit
dl
rm
is_discrete_interval.hpp
858
0644
edit
dl
rm
is_element_container.hpp
1781
0644
edit
dl
rm
is_icl_container.hpp
1177
0644
edit
dl
rm
is_increasing.hpp
978
0644
edit
dl
rm
is_interval.hpp
5823
0644
edit
dl
rm
is_interval_container.hpp
1486
0644
edit
dl
rm
is_interval_joiner.hpp
849
0644
edit
dl
rm
is_interval_separator.hpp
861
0644
edit
dl
rm
is_interval_splitter.hpp
857
0644
edit
dl
rm
is_key_container_of.hpp
2879
0644
edit
dl
rm
is_map.hpp
800
0644
edit
dl
rm
is_numeric.hpp
2859
0644
edit
dl
rm
is_set.hpp
869
0644
edit
dl
rm
is_total.hpp
780
0644
edit
dl
rm
no_type.hpp
654
0644
edit
dl
rm
predicate.hpp
1480
0644
edit
dl
rm
rep_type_of.hpp
2162
0644
edit
dl
rm
segment_type_of.hpp
1454
0644
edit
dl
rm
size.hpp
693
0644
edit
dl
rm
size_type_of.hpp
2189
0644
edit
dl
rm
succ_pred.hpp
2365
0644
edit
dl
rm
to_string.hpp
1441
0644
edit
dl
rm
type_to_string.hpp
3494
0644
edit
dl
rm
unit_element.hpp
1519
0644
edit
dl
rm
value_size.hpp
1685
0644
edit
dl
rm
Edit:
/usr/include/boost/icl/type_traits/is_numeric.hpp
(2859B)
/*-----------------------------------------------------------------------------+ Copyright (c) 2010-2010: Joachim Faulhaber +------------------------------------------------------------------------------+ Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENCE.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +-----------------------------------------------------------------------------*/ #ifndef BOOST_ICL_TYPE_TRAITS_IS_NUMERIC_HPP_JOFA_100322 #define BOOST_ICL_TYPE_TRAITS_IS_NUMERIC_HPP_JOFA_100322 #include <limits> #include <complex> #include <functional> #include <boost/type_traits/is_floating_point.hpp> #include <boost/type_traits/is_integral.hpp> namespace boost{ namespace icl { template <class Type> struct is_fixed_numeric { typedef is_fixed_numeric type; BOOST_STATIC_CONSTANT(bool, value = (0 < std::numeric_limits<Type>::digits)); }; template <class Type> struct is_std_numeric { typedef is_std_numeric type; BOOST_STATIC_CONSTANT(bool, value = (std::numeric_limits<Type>::is_specialized)); }; template <class Type> struct is_std_integral { typedef is_std_integral type; BOOST_STATIC_CONSTANT(bool, value = (std::numeric_limits<Type>::is_integer)); }; template <class Type> struct is_numeric { typedef is_numeric type; BOOST_STATIC_CONSTANT(bool, value = (mpl::or_< is_std_numeric<Type> , boost::is_integral<Type> , is_std_integral<Type> >::value) ); }; template <class Type> struct is_numeric<std::complex<Type> > { typedef is_numeric type; BOOST_STATIC_CONSTANT(bool, value = true); }; //-------------------------------------------------------------------------- template<class Type, class Compare, bool Enable = false> struct numeric_minimum { static bool is_less_than(Type){ return true; } static bool is_less_than_or(Type, bool){ return true; } }; template<class Type> struct numeric_minimum<Type, std::less<Type>, true> { static bool is_less_than(Type value) { return std::less<Type>()((std::numeric_limits<Type>::min)(), value); } static bool is_less_than_or(Type value, bool cond) { return cond || is_less_than(value); } }; template<class Type> struct numeric_minimum<Type, std::greater<Type>, true> { static bool is_less_than(Type value) { return std::greater<Type>()((std::numeric_limits<Type>::max)(), value); } static bool is_less_than_or(Type value, bool cond) { return cond || is_less_than(value); } }; //-------------------------------------------------------------------------- template<class Type> struct is_non_floating_point { typedef is_non_floating_point type; BOOST_STATIC_CONSTANT(bool, value = (mpl::not_< is_floating_point<Type> >::value)); }; }} // namespace boost icl #endif
Save
cmd:
run