diff --git a/Triangulation_3/include/CGAL/Triangulation_segment_traverser_3.h b/Triangulation_3/include/CGAL/Triangulation_segment_traverser_3.h index d13c3a7c89d..533163978b9 100644 --- a/Triangulation_3/include/CGAL/Triangulation_segment_traverser_3.h +++ b/Triangulation_3/include/CGAL/Triangulation_segment_traverser_3.h @@ -652,14 +652,9 @@ public: case Locate_type::EDGE: { - //while (ltnext == Locate_type::EDGE - // && _cell_iterator != _cell_iterator.end() - // && are_equal(get_edge(), Edge(chnext, linext, ljnext))) - //{ - // ++_cell_iterator; - // chnext = Cell_handle(_cell_iterator); - // _cell_iterator.entry(ltnext, linext, ljnext); - //} + CGAL_assertion(_cell_iterator == _cell_iterator.end() + || !are_equal(get_edge(), Edge(chnext, linext, ljnext))); + if (_cell_iterator == _cell_iterator.end()) _curr_simplex = Cell_handle(_cell_iterator); else if (ltnext == Locate_type::EDGE) @@ -707,17 +702,10 @@ public: { case Locate_type::VERTEX: { - //while (ltnext == Locate_type::VERTEX - // && _cell_iterator != _cell_iterator.end() - // && get_vertex() == chnext->vertex(linext)//another cell with same vertex has been found - // && !triangulation().is_infinite(chnext)) - //{ - // ch = chnext; - - // ++_cell_iterator; - // chnext = Cell_handle(_cell_iterator); - // _cell_iterator.entry(ltnext, linext, ljnext); - //} + CGAL_assertion(_cell_iterator == _cell_iterator.end() + || get_vertex() != chnext->vertex(linext) + || triangulation().is_infinite(chnext)); + if (_cell_iterator == _cell_iterator.end()) { _curr_simplex = Cell_handle(_cell_iterator);