cleanup of (std::max) workaround

This commit is contained in:
Andreas Fabri 2010-09-10 09:47:56 +00:00
parent 67ad0c654a
commit 06ecd18ec7
2 changed files with 10 additions and 15 deletions

View File

@ -48,8 +48,7 @@ struct Random_convex_set_traits_2 : public Kernel {
FT
operator()( const Point_2& p) const
{
BOOST_USING_STD_MAX();
return max BOOST_PREVENT_MACRO_SUBSTITUTION ( CGAL_NTS abs( p.x()), CGAL_NTS abs( p.y()));
return (std::max)( CGAL_NTS abs( p.x()), CGAL_NTS abs( p.y()));
}
};

View File

@ -242,13 +242,11 @@ public:
// distributed on the segment from p to q except q, i.e. `*g' ==
// \lambda p + (1-\lambda)\, q where 0 <= \lambda < 1 . A single
// random number is needed from `rnd' for each point.
: Random_generator_base<P>( max BOOST_PREVENT_MACRO_SUBSTITUTION
( max BOOST_PREVENT_MACRO_SUBSTITUTION
( to_double(p.x()), to_double(q.x())),
max BOOST_PREVENT_MACRO_SUBSTITUTION
( to_double(p.y()),
to_double(q.y()))),
rnd) , _p(p), _q(q) {
: Random_generator_base<P>( (std::max)( (std::max)( to_double(p.x()), to_double(q.x())),
(std::max)( to_double(p.y()),
to_double(q.y()))),
rnd) , _p(p), _q(q)
{
generate_point();
}
const P& source() const { return _p; }
@ -288,12 +286,10 @@ public:
Points_on_segment_2() {}
Points_on_segment_2( const P& p, const P& q,
std::size_t mx, std::size_t i = 0)
: Generator_base<P>( max BOOST_PREVENT_MACRO_SUBSTITUTION
( max BOOST_PREVENT_MACRO_SUBSTITUTION
( to_double(p.x()), to_double(q.x())),
max BOOST_PREVENT_MACRO_SUBSTITUTION
( to_double(p.y()), to_double(q.y())))),
_p(p), _q(q), d_i(i), d_mx(mx) {
: Generator_base<P>( (std::max)( (std::max)( to_double(p.x()), to_double(q.x())),
(std::max)( to_double(p.y()), to_double(q.y())))),
_p(p), _q(q), d_i(i), d_mx(mx)
{
generate_point();
}
const P& source() const { return _p; }