I want to use range-v3 to enumerate a range. The range is produce by CGAL using the CGAL::Surface_mesh<K>::faces()
function, which returns a range for the faces in the mesh.
However, range-v3 can't attach views to an rvalue range, so I can't do
mesh.faces() | ranges::views::enumerate
I can store the result of mesh.faces()
into a temporary and then use that, but would be cool to be able to do this in one line.
Is there anyway to do this?