Fix warnings (#8712)

Revealed by #8704
This commit is contained in:
Sebastien Loriot 2025-02-05 08:20:29 +01:00 committed by GitHub
commit f72e69f8af
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 20 additions and 5 deletions

View File

@ -10,13 +10,29 @@ typedef Traits::edge_descriptor edge_descriptor;
typedef Traits::halfedge_descriptor halfedge_descriptor;
typedef Traits::vertex_descriptor vertex_descriptor;
typedef Traits::face_descriptor face_descriptor;
//typedef Kernel::Point_3 Point_3;
int main()
{
Om om;
for (Om::EdgeHandle ed : edges(om)) {
std::cout << "edge" << std::endl;
for (Om::EdgeHandle ed : edges(om))
{
CGAL_USE(ed);
}
for (edge_descriptor ed : edges(om))
{
CGAL_USE(ed);
}
for (halfedge_descriptor hd : halfedges(om))
{
CGAL_USE(hd);
}
for (face_descriptor fd : faces(om))
{
CGAL_USE(fd);
}
for (vertex_descriptor vd : vertices(om))
{
CGAL_USE(vd);
}
return 0;
}

View File

@ -346,11 +346,10 @@ struct Tester
// Test vertex iterators
//-------------------------------------------------------
std::cout << "Test vertex iterators\n";
const Vertex_handle& vertex_to_modify = c3t3.vertices_in_complex_begin();
Vertex_handle vertex_to_modify = c3t3.vertices_in_complex_begin();
Vertex_handle vertex_to_modify_copy = vertex_to_modify;
c3t3.remove_from_complex(vertex_to_modify);
// now `vertex_to_modify` is a dangling ref to a `Vertex_handle`
// use a copy of it: `vertex_to_modify_copy`
c3t3.add_to_complex(vertex_to_modify_copy,corner_index_bis);