From d5a764c41c169569a63e1d5524b610dff3e69d41 Mon Sep 17 00:00:00 2001 From: Sven Oesau Date: Mon, 8 Jan 2024 13:13:21 +0100 Subject: [PATCH] fixed test removed warning --- Property_map/include/CGAL/Property_container.h | 7 ++++--- Property_map/test/Property_map/test_Property_container.cpp | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/Property_map/include/CGAL/Property_container.h b/Property_map/include/CGAL/Property_container.h index c14e34adb4c..bbc52260b24 100644 --- a/Property_map/include/CGAL/Property_container.h +++ b/Property_map/include/CGAL/Property_container.h @@ -15,8 +15,9 @@ #include #include +#include +#include -// todo: maybe this could be avoided #include #ifndef DOXYGEN_RUNNING @@ -492,14 +493,14 @@ public: auto unused_end = unused_begin; // Determine if the group fits - if (std::distance(unused_begin, m_active_indices.end()) >= n) + if (std::distance(unused_begin, m_active_indices.end()) >= static_cast::iterator>::difference_type>(n)) unused_end = std::find_if( unused_begin, (std::min)(unused_begin + n, m_active_indices.end()), [](bool used) { return used; } ); // If the discovered range was large enough - if (std::distance(unused_begin, unused_end) >= n) { + if (std::distance(unused_begin, unused_end) >= static_cast::iterator>::difference_type>(n)) { // Mark the indices as used, and reset the properties of each of them // todo: it would be better to provide a function to set a range diff --git a/Property_map/test/Property_map/test_Property_container.cpp b/Property_map/test/Property_map/test_Property_container.cpp index 4a5a2bc4273..45698bae584 100644 --- a/Property_map/test/Property_map/test_Property_container.cpp +++ b/Property_map/test/Property_map/test_Property_container.cpp @@ -1,7 +1,7 @@ #include -using namespace CGAL::Properties; +using namespace CGAL::Properties::Experimental; void test_property_creation() {