Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MeshBoolean: fix GCC 14 compile error #4499

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

FliegendeWurst
Copy link

Otherwise the build fails with:

/build/source/src/libslic3r/MeshBoolean.cpp:161:16: error: non-const lvalue reference to type 'reference' (aka 'CGAL::SM_Vertex_index') cannot bind to a temporary of type 'reference' (aka 'CGAL::SM_Vertex_index')
  161 |     for (auto &vi : cgalmesh.vertices()) {
      |                ^  ~
/build/source/src/libslic3r/MeshBoolean.cpp:188:12: note: in instantiation of function template specialization 'Slic3r::MeshBoolean::cgal::cgal_to_triangle_mesh<CGAL::Surface_mesh<CGAL::Point_3<CGAL::Epick>>>' requested here
  188 |     return cgal_to_triangle_mesh(cgalmesh.m);
      |            ^
/nix/store/qg5xvm9icynvn84inj4g0z6zq9ibl06b-cgal-5.6.2/include/CGAL/Iterator_range.h:49:5: note: selected 'begin' function with iterator type 'CGAL::Surface_mesh<CGAL::Point_3<CGAL::Epick>>::Index_iterator<CGAL::SM_Vertex_index>'
   49 |   I begin() const
      |     ^
/build/source/src/libslic3r/MeshBoolean.cpp:166:16: error: non-const lvalue reference to type 'reference' (aka 'CGAL::SM_Face_index') cannot bind to a temporary of type 'reference' (aka 'CGAL::SM_Face_index')
  166 |     for (auto &face : cgalmesh.faces()) {
      |                ^    ~
/nix/store/qg5xvm9icynvn84inj4g0z6zq9ibl06b-cgal-5.6.2/include/CGAL/Iterator_range.h:49:5: note: selected 'begin' function with iterator type 'CGAL::Surface_mesh<CGAL::Point_3<CGAL::Epick>>::Index_iterator<CGAL::SM_Face_index>'
   49 |   I begin() const
      |     ^
3 warnings and 2 errors generated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant