From 0ee9e284557b8cfc9cd4dabd0a89b99b54cc6de8 Mon Sep 17 00:00:00 2001 From: Eric Berberich Date: Fri, 10 Oct 2014 16:29:36 +0200 Subject: [PATCH] added assertion --- .../include/CGAL/Sweep_line_2/Basic_sweep_line_2_impl.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Arrangement_on_surface_2/include/CGAL/Sweep_line_2/Basic_sweep_line_2_impl.h b/Arrangement_on_surface_2/include/CGAL/Sweep_line_2/Basic_sweep_line_2_impl.h index 8ee8021e262..41fcbd0d658 100644 --- a/Arrangement_on_surface_2/include/CGAL/Sweep_line_2/Basic_sweep_line_2_impl.h +++ b/Arrangement_on_surface_2/include/CGAL/Sweep_line_2/Basic_sweep_line_2_impl.h @@ -292,6 +292,11 @@ _init_curve_end(const X_monotone_curve_2& cv, Arr_curve_end ind, Subcurve* sc) // Get the parameter space of the curve end. Arr_parameter_space ps_x = m_traits->parameter_space_in_x_2_object()(cv, ind); Arr_parameter_space ps_y = m_traits->parameter_space_in_y_2_object()(cv, ind); +#if 0 + CGAL::set_pretty_mode(std::cout); + std::cout << "init ce ps_x: " << ps_x << std::endl; + std::cout << "init ce ps_y: " << ps_y << std::endl; +#endif // Create the corresponding event and push it into the event queue. std::pair pair_res = _push_event(cv, ind, end_attr, ps_x, ps_y, sc); @@ -643,6 +648,8 @@ _push_event(const Point_2& pt, Attribute type, e->set_attribute(type); } + CGAL_assertion(e->parameter_space_in_x() == ps_x); + CGAL_assertion(e->parameter_space_in_y() == ps_y); // If we are given a subcurve that the event represents one of its // endpoints, update the event and the subcurve records accordingly.