mirror of https://github.com/CGAL/cgal
Replace some boost with std.
It doesn't help much, but we should still stop using those boost facilities that are now standard.
This commit is contained in:
parent
9fef604bc2
commit
02cfcafb72
|
|
@ -28,6 +28,7 @@
|
|||
#include <CGAL/transforming_iterator.h>
|
||||
#include <CGAL/NewKernel_d/store_kernel.h>
|
||||
#include <CGAL/Dimension.h>
|
||||
#include <type_traits>
|
||||
|
||||
namespace CGAL {
|
||||
namespace CartesianDVectorBase {
|
||||
|
|
@ -66,7 +67,7 @@ template<class R_,class Zero_> struct Construct_LA_vector
|
|||
}
|
||||
template<class...U>
|
||||
typename std::enable_if<Constructible_from_each<RT,U...>::value &&
|
||||
boost::is_same<Dimension_tag<sizeof...(U)>, Dimension>::value,
|
||||
std::is_same<Dimension_tag<sizeof...(U)>, Dimension>::value,
|
||||
result_type>::type
|
||||
operator()(U&&...u)const{
|
||||
return typename Constructor::Values()(std::forward<U>(u)...);
|
||||
|
|
@ -74,19 +75,19 @@ template<class R_,class Zero_> struct Construct_LA_vector
|
|||
//template<class...U,class=typename std::enable_if<Constructible_from_each<RT,U...>::value>::type,class=typename std::enable_if<(sizeof...(U)==static_dim+1)>::type,class=void>
|
||||
template<class...U>
|
||||
typename std::enable_if<Constructible_from_each<RT,U...>::value &&
|
||||
boost::is_same<Dimension_tag<sizeof...(U)-1>, Dimension>::value,
|
||||
std::is_same<Dimension_tag<sizeof...(U)-1>, Dimension>::value,
|
||||
result_type>::type
|
||||
operator()(U&&...u)const{
|
||||
return Apply_to_last_then_rest()(typename Constructor::Values_divide(),std::forward<U>(u)...);
|
||||
}
|
||||
template<class Iter> inline
|
||||
typename boost::enable_if<is_iterator_type<Iter,std::forward_iterator_tag>,result_type>::type operator()
|
||||
typename std::enable_if_t<is_iterator_type<Iter,std::forward_iterator_tag>::value,result_type> operator()
|
||||
(Iter f,Iter g,Cartesian_tag t)const
|
||||
{
|
||||
return this->operator()((int)std::distance(f,g),f,g,t);
|
||||
}
|
||||
template<class Iter> inline
|
||||
typename boost::enable_if<is_iterator_type<Iter,std::forward_iterator_tag>,result_type>::type operator()
|
||||
typename std::enable_if_t<is_iterator_type<Iter,std::forward_iterator_tag>::value,result_type> operator()
|
||||
(int d,Iter f,Iter g,Cartesian_tag)const
|
||||
{
|
||||
CGAL_assertion(d==std::distance(f,g));
|
||||
|
|
@ -94,28 +95,28 @@ template<class R_,class Zero_> struct Construct_LA_vector
|
|||
return typename Constructor::Iterator()(d,f,g);
|
||||
}
|
||||
template<class Iter> inline
|
||||
typename boost::enable_if<is_iterator_type<Iter,std::bidirectional_iterator_tag>,result_type>::type operator()
|
||||
typename std::enable_if_t<is_iterator_type<Iter,std::bidirectional_iterator_tag>::value,result_type> operator()
|
||||
(Iter f,Iter g,Homogeneous_tag)const
|
||||
{
|
||||
--g;
|
||||
return this->operator()((int)std::distance(f,g),f,g,*g);
|
||||
}
|
||||
template<class Iter> inline
|
||||
typename boost::enable_if<is_iterator_type<Iter,std::bidirectional_iterator_tag>,result_type>::type operator()
|
||||
typename std::enable_if_t<is_iterator_type<Iter,std::bidirectional_iterator_tag>::value,result_type> operator()
|
||||
(int d,Iter f,Iter g,Homogeneous_tag)const
|
||||
{
|
||||
--g;
|
||||
return this->operator()(d,f,g,*g);
|
||||
}
|
||||
template<class Iter> inline
|
||||
typename boost::enable_if<is_iterator_type<Iter,std::forward_iterator_tag>,result_type>::type operator()
|
||||
typename std::enable_if_t<is_iterator_type<Iter,std::forward_iterator_tag>::value,result_type> operator()
|
||||
(Iter f,Iter g)const
|
||||
{
|
||||
// Shouldn't it try comparing dist(f,g) to the dimension if it is known?
|
||||
return this->operator()(f,g,typename R::Rep_tag());
|
||||
}
|
||||
template<class Iter> inline
|
||||
typename boost::enable_if<is_iterator_type<Iter,std::forward_iterator_tag>,result_type>::type operator()
|
||||
typename std::enable_if_t<is_iterator_type<Iter,std::forward_iterator_tag>::value,result_type> operator()
|
||||
(int d,Iter f,Iter g)const
|
||||
{
|
||||
return this->operator()(d,f,g,typename R::Rep_tag());
|
||||
|
|
@ -123,7 +124,7 @@ template<class R_,class Zero_> struct Construct_LA_vector
|
|||
|
||||
// Last homogeneous coordinate given separately
|
||||
template<class Iter,class NT> inline
|
||||
typename boost::enable_if<is_iterator_type<Iter,std::forward_iterator_tag>,result_type>::type operator()
|
||||
typename std::enable_if_t<is_iterator_type<Iter,std::forward_iterator_tag>::value,result_type> operator()
|
||||
(int d,Iter f,Iter g,NT const&l)const
|
||||
{
|
||||
CGAL_assertion(d==std::distance(f,g));
|
||||
|
|
@ -132,7 +133,7 @@ template<class R_,class Zero_> struct Construct_LA_vector
|
|||
return typename Constructor::Iterator()(d,CGAL::make_transforming_iterator(f,Divide<FT,NT>(l)),CGAL::make_transforming_iterator(g,Divide<FT,NT>(l)));
|
||||
}
|
||||
template<class Iter,class NT> inline
|
||||
typename boost::enable_if<is_iterator_type<Iter,std::forward_iterator_tag>,result_type>::type operator()
|
||||
typename std::enable_if_t<is_iterator_type<Iter,std::forward_iterator_tag>::value,result_type> operator()
|
||||
(Iter f,Iter g,NT const&l)const
|
||||
{
|
||||
return this->operator()((int)std::distance(f,g),f,g,l);
|
||||
|
|
|
|||
Loading…
Reference in New Issue