From e6d9ab3a8e506d2674db76a789bc3b5980ca8abe Mon Sep 17 00:00:00 2001 From: Vissarion Fisikopoulos Date: Wed, 5 Jul 2023 13:18:44 +0300 Subject: [PATCH] Remove unused comments related to less compare policy --- .../detail/convex_hull/graham_andrew.hpp | 1 - .../detail/disjoint/multipoint_geometry.hpp | 8 +++----- .../detail/distance/segment_to_box.hpp | 2 -- .../detail/is_simple/multipoint.hpp | 1 - .../detail/is_valid/complement_graph.hpp | 1 - .../detail/overlay/pointlike_pointlike.hpp | 1 - .../detail/relate/boundary_checker.hpp | 1 - .../detail/relate/multi_point_geometry.hpp | 2 -- .../algorithms/detail/relate/point_point.hpp | 1 - .../detail/relate/topology_check.hpp | 1 - .../algorithms/detail/within/multi_point.hpp | 1 - .../geometry/algorithms/merge_elements.hpp | 1 - include/boost/geometry/policies/compare.hpp | 19 ------------------- 13 files changed, 3 insertions(+), 37 deletions(-) diff --git a/include/boost/geometry/algorithms/detail/convex_hull/graham_andrew.hpp b/include/boost/geometry/algorithms/detail/convex_hull/graham_andrew.hpp index 7c1c7cd8c..102318eeb 100644 --- a/include/boost/geometry/algorithms/detail/convex_hull/graham_andrew.hpp +++ b/include/boost/geometry/algorithms/detail/convex_hull/graham_andrew.hpp @@ -224,7 +224,6 @@ private: point_type const& left, point_type const& right, SideStrategy const& side) { - //std::cout << "add to hull" << std::endl; output.push_back(left); for (auto const& i : input) { diff --git a/include/boost/geometry/algorithms/detail/disjoint/multipoint_geometry.hpp b/include/boost/geometry/algorithms/detail/disjoint/multipoint_geometry.hpp index 35d8bd686..535c9006b 100644 --- a/include/boost/geometry/algorithms/detail/disjoint/multipoint_geometry.hpp +++ b/include/boost/geometry/algorithms/detail/disjoint/multipoint_geometry.hpp @@ -68,12 +68,11 @@ private: : geometry::less { private: - //TODO: pass strategy - typedef geometry::less base_type; + using less_type = geometry::less; public: unary_not_disjoint_predicate(Iterator first, Iterator last) - : base_type(), m_first(first), m_last(last) + : less_type(), m_first(first), m_last(last) {} template @@ -82,7 +81,7 @@ private: return std::binary_search(m_first, m_last, point, - static_cast(*this)); + static_cast(*this)); } private: @@ -97,7 +96,6 @@ public: { BOOST_GEOMETRY_ASSERT( boost::size(multipoint1) <= boost::size(multipoint2) ); - //TODO: pass strategy using less_type = geometry::less; using point1_type = typename boost::range_value::type; diff --git a/include/boost/geometry/algorithms/detail/distance/segment_to_box.hpp b/include/boost/geometry/algorithms/detail/distance/segment_to_box.hpp index 516cb99f2..09f3cc4f6 100644 --- a/include/boost/geometry/algorithms/detail/distance/segment_to_box.hpp +++ b/include/boost/geometry/algorithms/detail/distance/segment_to_box.hpp @@ -658,7 +658,6 @@ public: BoxPoint const& bottom_right, Strategies const& strategies) { - //TODO: pass strategy BOOST_GEOMETRY_ASSERT( (geometry::less()(p0, p1)) || geometry::has_nan_coordinate(p0) || geometry::has_nan_coordinate(p1) ); @@ -754,7 +753,6 @@ public: bottom_left, bottom_right, top_left, top_right); - //TODO: pass strategy typedef geometry::less less_type; if (less_type()(p[0], p[1])) { diff --git a/include/boost/geometry/algorithms/detail/is_simple/multipoint.hpp b/include/boost/geometry/algorithms/detail/is_simple/multipoint.hpp index 239aa2580..2eba68f97 100644 --- a/include/boost/geometry/algorithms/detail/is_simple/multipoint.hpp +++ b/include/boost/geometry/algorithms/detail/is_simple/multipoint.hpp @@ -45,7 +45,6 @@ struct is_simple_multipoint template static inline bool apply(MultiPoint const& multipoint, Strategy const& strategy) { - //TODO: pass strategy typedef geometry::less < typename point_type::type, diff --git a/include/boost/geometry/algorithms/detail/is_valid/complement_graph.hpp b/include/boost/geometry/algorithms/detail/is_valid/complement_graph.hpp index 193f8bc89..9a51d30eb 100644 --- a/include/boost/geometry/algorithms/detail/is_valid/complement_graph.hpp +++ b/include/boost/geometry/algorithms/detail/is_valid/complement_graph.hpp @@ -54,7 +54,6 @@ public: { if ( m_turn_point != NULL && other.m_turn_point != NULL ) { - //TODO: pass strategy return geometry::less < TurnPoint, -1, Strategy diff --git a/include/boost/geometry/algorithms/detail/overlay/pointlike_pointlike.hpp b/include/boost/geometry/algorithms/detail/overlay/pointlike_pointlike.hpp index 0c75121b5..e95da35f5 100644 --- a/include/boost/geometry/algorithms/detail/overlay/pointlike_pointlike.hpp +++ b/include/boost/geometry/algorithms/detail/overlay/pointlike_pointlike.hpp @@ -255,7 +255,6 @@ struct multipoint_multipoint_point OutputIterator oit, Strategy const& strategy) { - //TODO: pass strategy typedef geometry::less less_type; if ( OverlayType != overlay_difference diff --git a/include/boost/geometry/algorithms/detail/relate/boundary_checker.hpp b/include/boost/geometry/algorithms/detail/relate/boundary_checker.hpp index 41891e491..0d95aabac 100644 --- a/include/boost/geometry/algorithms/detail/relate/boundary_checker.hpp +++ b/include/boost/geometry/algorithms/detail/relate/boundary_checker.hpp @@ -162,7 +162,6 @@ public: template bool is_endpoint_boundary(Point const& pt) const { - //TODO: pass strategy using less_type = geometry::less; auto const multi_count = boost::size(m_geometry); diff --git a/include/boost/geometry/algorithms/detail/relate/multi_point_geometry.hpp b/include/boost/geometry/algorithms/detail/relate/multi_point_geometry.hpp index 5d14e100f..204a4fe22 100644 --- a/include/boost/geometry/algorithms/detail/relate/multi_point_geometry.hpp +++ b/include/boost/geometry/algorithms/detail/relate/multi_point_geometry.hpp @@ -135,7 +135,6 @@ struct multi_point_geometry_eb template bool apply(Point const& boundary_point, Strategy const&) { - //TODO: pass strategy typedef geometry::less less_type; if (! std::binary_search(m_points.begin(), m_points.end(), @@ -160,7 +159,6 @@ struct multi_point_geometry_eb { typedef typename boost::range_value::type point_type; typedef std::vector points_type; - //TODO: pass strategy typedef geometry::less less_type; points_type points(boost::begin(multi_point), boost::end(multi_point)); diff --git a/include/boost/geometry/algorithms/detail/relate/point_point.hpp b/include/boost/geometry/algorithms/detail/relate/point_point.hpp index ab87ca5b9..c987bb44c 100644 --- a/include/boost/geometry/algorithms/detail/relate/point_point.hpp +++ b/include/boost/geometry/algorithms/detail/relate/point_point.hpp @@ -222,7 +222,6 @@ struct multipoint_multipoint { // sort points from the 1 MPt typedef typename geometry::point_type::type point_type; - //TODO: pass strategy typedef geometry::less less_type; std::vector points(boost::begin(sorted_mpt), boost::end(sorted_mpt)); diff --git a/include/boost/geometry/algorithms/detail/relate/topology_check.hpp b/include/boost/geometry/algorithms/detail/relate/topology_check.hpp index 8351f0d00..2fc31ab51 100644 --- a/include/boost/geometry/algorithms/detail/relate/topology_check.hpp +++ b/include/boost/geometry/algorithms/detail/relate/topology_check.hpp @@ -171,7 +171,6 @@ struct topology_check } private: - //TODO: pass strategy typedef geometry::less less_type; void init() const diff --git a/include/boost/geometry/algorithms/detail/within/multi_point.hpp b/include/boost/geometry/algorithms/detail/within/multi_point.hpp index 66f28e203..68497c049 100644 --- a/include/boost/geometry/algorithms/detail/within/multi_point.hpp +++ b/include/boost/geometry/algorithms/detail/within/multi_point.hpp @@ -79,7 +79,6 @@ struct multi_point_multi_point Strategy const& /*strategy*/) { typedef typename boost::range_value::type point2_type; - //TODO: pass strategy typedef geometry::less less_type; less_type const less = less_type(); diff --git a/include/boost/geometry/algorithms/merge_elements.hpp b/include/boost/geometry/algorithms/merge_elements.hpp index 76a0fa74c..796e44500 100644 --- a/include/boost/geometry/algorithms/merge_elements.hpp +++ b/include/boost/geometry/algorithms/merge_elements.hpp @@ -173,7 +173,6 @@ inline void merge(RandomIt const first, RandomIt const last, MultiGeometry& out, auto const less = [](auto const& l, auto const& r) { - //TODO: pass strategy return geometry::less()(l.first, r.first); }; diff --git a/include/boost/geometry/policies/compare.hpp b/include/boost/geometry/policies/compare.hpp index 892317e17..8538fdfa9 100644 --- a/include/boost/geometry/policies/compare.hpp +++ b/include/boost/geometry/policies/compare.hpp @@ -52,25 +52,6 @@ struct less inline bool operator()(Point const& left, Point const& right) const { - /*using strategy_type = typename strategy::compare::services::default_strategy - < - strategy::compare::less, - strategy::compare::equals_epsilon, - Point, Point, - Dimension - >::type; - - Strategy strategy; - using compare_strategy = decltype( - strategy.template compare - < - strategy::compare::less, - strategy::compare::equals_exact, - -1 - >()); - - return compare_strategy::apply(left, right); -*/ return Strategy::template compare_type < strategy::compare::less