diff --git a/Arrangement_on_surface_2/include/CGAL/Arr_geometry_traits/Conic_x_monotone_arc_2.h b/Arrangement_on_surface_2/include/CGAL/Arr_geometry_traits/Conic_x_monotone_arc_2.h index 761e38b1693..ec70376642b 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arr_geometry_traits/Conic_x_monotone_arc_2.h +++ b/Arrangement_on_surface_2/include/CGAL/Arr_geometry_traits/Conic_x_monotone_arc_2.h @@ -202,7 +202,7 @@ public: // Invalid arc: if (dir_res == EQUAL) return; - this->_info = (Conic_arc_2::IS_VALID | DEGREE_1); + this->_info = (static_cast(Conic_arc_2::IS_VALID) | static_cast(DEGREE_1)); if (dir_res == SMALLER) this->_info = (this->_info | IS_DIRECTED_RIGHT); diff --git a/CGAL_Core/include/CGAL/CORE/BigFloatRep.h b/CGAL_Core/include/CGAL/CORE/BigFloatRep.h index 25cfd243264..7439ce025a9 100644 --- a/CGAL_Core/include/CGAL/CORE/BigFloatRep.h +++ b/CGAL_Core/include/CGAL/CORE/BigFloatRep.h @@ -423,7 +423,7 @@ inline std::string BigFloatRep::toString(long prec, bool sci) const { else return r.rep; } - return nullptr; + return std::string(); } inline void BigFloatRep::dump() const { diff --git a/Installation/include/CGAL/Installation/internal/enable_third_party_libraries.h b/Installation/include/CGAL/Installation/internal/enable_third_party_libraries.h index 9375f7229b1..1e4f7bb3ca0 100644 --- a/Installation/include/CGAL/Installation/internal/enable_third_party_libraries.h +++ b/Installation/include/CGAL/Installation/internal/enable_third_party_libraries.h @@ -27,11 +27,11 @@ #if defined(__has_include) # if CGAL_USE_GMP && ! __has_include() -# warning " cannot be found. Less efficient number types will be used instead. Define CGAL_NO_GMP=1 if that is on purpose." +# pragma CGAL_WARNING( cannot be found. Less efficient number types will be used instead. Define CGAL_NO_GMP=1 if that is on purpose.) # undef CGAL_USE_GMP # undef CGAL_USE_MPFR # elif CGAL_USE_MPFR && ! __has_include() -# warning " cannot be found and the GMP support in CGAL requires it. Less efficient number types will be used instead. Define CGAL_NO_GMP=1 if that is on purpose." +# pragma CGAL_WARNING( cannot be found and the GMP support in CGAL requires it. Less efficient number types will be used instead. Define CGAL_NO_GMP=1 if that is on purpose.) # undef CGAL_USE_GMP # undef CGAL_USE_MPFR # endif // CGAL_USE_MPFR and no diff --git a/NewKernel_d/include/CGAL/NewKernel_d/LA_eigen/constructors.h b/NewKernel_d/include/CGAL/NewKernel_d/LA_eigen/constructors.h index 1bb4b2a33ef..1341a28f7df 100644 --- a/NewKernel_d/include/CGAL/NewKernel_d/LA_eigen/constructors.h +++ b/NewKernel_d/include/CGAL/NewKernel_d/LA_eigen/constructors.h @@ -92,7 +92,7 @@ namespace CGAL { struct Initializer_list { result_type operator()(std::initializer_list l) const { - return Iterator()(l.size(),l.begin(),l.end()); + return Iterator()(static_cast(l.size()),l.begin(),l.end()); } }; diff --git a/Periodic_3_triangulation_3/demo/Periodic_3_triangulation_3/Scene_utils.h b/Periodic_3_triangulation_3/demo/Periodic_3_triangulation_3/Scene_utils.h index 57b73291b68..7df55ddcbd7 100644 --- a/Periodic_3_triangulation_3/demo/Periodic_3_triangulation_3/Scene_utils.h +++ b/Periodic_3_triangulation_3/demo/Periodic_3_triangulation_3/Scene_utils.h @@ -57,7 +57,6 @@ class Projected_triangle { public: Projected_triangle() {} Projected_triangle(double z, Triangle tr) : m_z(z), m_t(tr) {} - Projected_triangle(const Projected_triangle &pt) : m_z(pt.z()), m_t(pt.t()) {} Triangle t() { return m_t; } const Triangle t() const { return m_t; } diff --git a/Polygon_mesh_processing/include/CGAL/Polygon_mesh_processing/internal/AABB_traversal_traits_with_Hausdorff_distance.h b/Polygon_mesh_processing/include/CGAL/Polygon_mesh_processing/internal/AABB_traversal_traits_with_Hausdorff_distance.h index a7f5ddd01ea..b08f8269fca 100644 --- a/Polygon_mesh_processing/include/CGAL/Polygon_mesh_processing/internal/AABB_traversal_traits_with_Hausdorff_distance.h +++ b/Polygon_mesh_processing/include/CGAL/Polygon_mesh_processing/internal/AABB_traversal_traits_with_Hausdorff_distance.h @@ -207,26 +207,26 @@ namespace CGAL { // Compute distance of the bounding boxes. // Distance along the x-axis. FT dist_x = FT(0); - if (tri_max.x() < bbox.min(0)) { - dist_x = bbox.min(0) - tri_max.x(); - } else if (bbox.max(0) < tri_min.x()) { - dist_x = tri_min.x() - bbox.max(0); + if (tri_max.x() < (bbox.min)(0)) { + dist_x = (bbox.min)(0) - tri_max.x(); + } else if ((bbox.max)(0) < tri_min.x()) { + dist_x = tri_min.x() - (bbox.max)(0); } // Distance along the y-axis. FT dist_y = FT(0); - if (tri_max.y() < bbox.min(1)) { - dist_y = bbox.min(1) - tri_max.y(); - } else if (bbox.max(1) < tri_min.y()) { - dist_y = tri_min.y() - bbox.max(1); + if (tri_max.y() < (bbox.min)(1)) { + dist_y = (bbox.min)(1) - tri_max.y(); + } else if ((bbox.max)(1) < tri_min.y()) { + dist_y = tri_min.y() - (bbox.max)(1); } // Distance along the z-axis. FT dist_z = FT(0); - if (tri_max.z() < bbox.min(2)) { - dist_z = bbox.min(2) - tri_max.z(); - } else if (bbox.max(2) < tri_min.z()) { - dist_z = tri_min.z() - bbox.max(2); + if (tri_max.z() < (bbox.min)(2)) { + dist_z = (bbox.min)(2) - tri_max.z(); + } else if ((bbox.max)(2) < tri_min.z()) { + dist_z = tri_min.z() - (bbox.max)(2); } // Lower bound on the distance between the two bounding boxes is given @@ -443,11 +443,11 @@ namespace CGAL { // Shift the vector to be the difference between the farthest corner // of the bounding box away from the closest point on TM2. - FT diff_x = (bbox.max(0) - bbox.min(0)) / FT(2); + FT diff_x = ((bbox.max)(0) - (bbox.min)(0)) / FT(2); if (difference.x() < 0) diff_x = diff_x * -FT(1); - FT diff_y = (bbox.max(1) - bbox.min(1)) / FT(2); + FT diff_y = ((bbox.max)(1) - (bbox.min)(1)) / FT(2); if (difference.y() < 0) diff_y = diff_y * -FT(1); - FT diff_z = (bbox.max(2) - bbox.min(2)) / FT(2); + FT diff_z = ((bbox.max)(2) - (bbox.min)(2)) / FT(2); if (difference.z() < 0) diff_z = diff_z * -FT(1); difference = difference + Vector_3(diff_x, diff_y, diff_z); // it is (9) in the paper diff --git a/Polyhedron/demo/Polyhedron/include/CGAL/Polyhedron_kernel.h b/Polyhedron/demo/Polyhedron/include/CGAL/Polyhedron_kernel.h index 0028d9f10d3..1652e42e9b6 100644 --- a/Polyhedron/demo/Polyhedron/include/CGAL/Polyhedron_kernel.h +++ b/Polyhedron/demo/Polyhedron/include/CGAL/Polyhedron_kernel.h @@ -94,7 +94,7 @@ public: lp.set_a(index_x4, j, -1.0); // -x4 // right hand side (>= -dj) - FT dj = distance_to_origin(plane) * CGAL::sign(plane.d()); + FT dj = distance_to_origin(plane) * static_cast(CGAL::sign(plane.d())); lp.set_b(j, -dj); } diff --git a/Stream_support/include/CGAL/IO/OFF/generic_copy_OFF.h b/Stream_support/include/CGAL/IO/OFF/generic_copy_OFF.h index 799691de51a..165859b3c80 100644 --- a/Stream_support/include/CGAL/IO/OFF/generic_copy_OFF.h +++ b/Stream_support/include/CGAL/IO/OFF/generic_copy_OFF.h @@ -71,12 +71,12 @@ generic_copy_OFF(File_scanner_OFF& scanner, if(! in) return; - std::size_t no; + std::size_t no = 0; scanner.scan_facet(no, i); writer.write_facet_begin(no); for(std::size_t j=0; j -typename Optional_or_bool::type>::type +typename Optional_or_bool::type>::type wrap_a_call_to_cpp(Callable f, QScriptable* qs = 0, const char* file = 0, int line = -1, Context c = CURRENT_CONTEXT) { - typedef typename std::result_of::type Callable_RT; + typedef typename cpp11::result_of::type Callable_RT; typedef Optional_or_bool O_r_b; typedef typename O_r_b::type Return_type;