From a8bd3605a7e7a6206720fedf8bf43927e4754b6f Mon Sep 17 00:00:00 2001 From: Laurent Rineau Date: Thu, 26 Apr 2018 16:16:10 +0200 Subject: [PATCH 01/17] A fix for MSVC 2017 15.7 with /permissive- MSVC is probably right that it was not a valid C++ code: the previous version called a static member function of the enclosing class, without qualification, and that static member function was defined *after*. --- AABB_tree/include/CGAL/AABB_traits.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/AABB_tree/include/CGAL/AABB_traits.h b/AABB_tree/include/CGAL/AABB_traits.h index 638153dc6c1..4b962f14658 100644 --- a/AABB_tree/include/CGAL/AABB_traits.h +++ b/AABB_tree/include/CGAL/AABB_traits.h @@ -291,7 +291,8 @@ public: */ class Sort_primitives { - const AABB_traits& m_traits; + typedef AABB_traits Traits; + const Traits& m_traits; public: Sort_primitives(const AABB_traits& traits) : m_traits(traits) {} @@ -302,7 +303,7 @@ public: const typename AT::Bounding_box& bbox) const { PrimitiveIterator middle = first + (beyond - first)/2; - switch(longest_axis(bbox)) + switch(Traits::longest_axis(bbox)) { case AT::CGAL_AXIS_X: // sort along x std::nth_element(first, middle, beyond, boost::bind(less_x,_1,_2,m_traits)); From d2b89df177548185779147b9d446b3f03e245d42 Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Wed, 2 May 2018 15:14:46 +0100 Subject: [PATCH 02/17] More Traits:: --- AABB_tree/include/CGAL/AABB_traits.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/AABB_tree/include/CGAL/AABB_traits.h b/AABB_tree/include/CGAL/AABB_traits.h index 4b962f14658..8cbbd4ebdf3 100644 --- a/AABB_tree/include/CGAL/AABB_traits.h +++ b/AABB_tree/include/CGAL/AABB_traits.h @@ -306,13 +306,13 @@ public: switch(Traits::longest_axis(bbox)) { case AT::CGAL_AXIS_X: // sort along x - std::nth_element(first, middle, beyond, boost::bind(less_x,_1,_2,m_traits)); + std::nth_element(first, middle, beyond, boost::bind(Traits::less_x,_1,_2,m_traits)); break; case AT::CGAL_AXIS_Y: // sort along y - std::nth_element(first, middle, beyond, boost::bind(less_y,_1,_2,m_traits)); + std::nth_element(first, middle, beyond, boost::bind(Traits::less_y,_1,_2,m_traits)); break; case AT::CGAL_AXIS_Z: // sort along z - std::nth_element(first, middle, beyond, boost::bind(less_z,_1,_2,m_traits)); + std::nth_element(first, middle, beyond, boost::bind(Traits::less_z,_1,_2,m_traits)); break; default: CGAL_error(); From 887766a0e1fc985580c67cd2ff33190ca99abe34 Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Tue, 8 May 2018 17:12:10 +0100 Subject: [PATCH 03/17] Postfix class names with _2 and _3 as they are different --- Alpha_shapes_2/include/CGAL/internal/Lazy_alpha_nt_2.h | 8 ++++---- Alpha_shapes_3/include/CGAL/internal/Lazy_alpha_nt_3.h | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Alpha_shapes_2/include/CGAL/internal/Lazy_alpha_nt_2.h b/Alpha_shapes_2/include/CGAL/internal/Lazy_alpha_nt_2.h index eaafd27f71d..83eeac727d5 100644 --- a/Alpha_shapes_2/include/CGAL/internal/Lazy_alpha_nt_2.h +++ b/Alpha_shapes_2/include/CGAL/internal/Lazy_alpha_nt_2.h @@ -45,7 +45,7 @@ namespace internal { // template < class Input_traits, class Kernel_approx, class Kernel_exact, class Weighted_tag > -class Is_traits_point_convertible +class Is_traits_point_convertible_2 { typedef typename Kernel_traits::Kernel Kernel_input; @@ -60,7 +60,7 @@ public: }; template < class Input_traits, class Kernel_approx, class Kernel_exact > -class Is_traits_point_convertible { typedef typename Kernel_traits::Kernel Kernel_input; @@ -157,7 +157,7 @@ class Lazy_alpha_nt_2 Approx_point to_approx(const Input_point& wp) const { // The traits class' Point_2 must be convertible using the Cartesian converter - CGAL_static_assertion((Is_traits_point_convertible< + CGAL_static_assertion((Is_traits_point_convertible_2< Input_traits, Kernel_approx, Kernel_exact, Weighted_tag>::value)); To_approx converter; @@ -167,7 +167,7 @@ class Lazy_alpha_nt_2 Exact_point to_exact(const Input_point& wp) const { // The traits class' Point_2 must be convertible using the Cartesian converter - CGAL_static_assertion((Is_traits_point_convertible< + CGAL_static_assertion((Is_traits_point_convertible_2< Input_traits, Kernel_approx, Kernel_exact, Weighted_tag>::value)); To_exact converter; diff --git a/Alpha_shapes_3/include/CGAL/internal/Lazy_alpha_nt_3.h b/Alpha_shapes_3/include/CGAL/internal/Lazy_alpha_nt_3.h index 8a4effe1a4b..97005825a79 100644 --- a/Alpha_shapes_3/include/CGAL/internal/Lazy_alpha_nt_3.h +++ b/Alpha_shapes_3/include/CGAL/internal/Lazy_alpha_nt_3.h @@ -45,7 +45,7 @@ namespace internal{ // template < class Input_traits, class Kernel_approx, class Kernel_exact, class Weighted_tag > -class Is_traits_point_convertible +class Is_traits_point_convertible_3 { typedef typename Kernel_traits::Kernel Kernel_input; @@ -60,7 +60,7 @@ public: }; template < class Input_traits, class Kernel_approx, class Kernel_exact > -class Is_traits_point_convertible { typedef typename Kernel_traits::Kernel Kernel_input; @@ -148,7 +148,7 @@ class Lazy_alpha_nt_3{ Approx_point to_approx(const Input_point& wp) const { // The traits class' Point_3 must be convertible using the Cartesian converter - CGAL_static_assertion((Is_traits_point_convertible< + CGAL_static_assertion((Is_traits_point_convertible_3< Input_traits, Kernel_approx, Kernel_exact, Weighted_tag>::value)); To_approx converter; @@ -158,7 +158,7 @@ class Lazy_alpha_nt_3{ Exact_point to_exact(const Input_point& wp) const { // The traits class' Point_3 must be convertible using the Cartesian converter - CGAL_static_assertion((Is_traits_point_convertible< + CGAL_static_assertion((Is_traits_point_convertible_3< Input_traits, Kernel_approx, Kernel_exact, Weighted_tag>::value)); To_exact converter; From b4f16e759c53e00eaef767b8c9cb3c2ef3cfc640 Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Wed, 9 May 2018 10:05:27 +0100 Subject: [PATCH 04/17] Remove a redundant figure and add the word 'conforming' --- Mesh_2/doc/Mesh_2/Mesh_2.txt | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/Mesh_2/doc/Mesh_2/Mesh_2.txt b/Mesh_2/doc/Mesh_2/Mesh_2.txt index 7d6484b1f90..3ff3e3797f4 100644 --- a/Mesh_2/doc/Mesh_2/Mesh_2.txt +++ b/Mesh_2/doc/Mesh_2/Mesh_2.txt @@ -98,11 +98,7 @@ printed. See \cgalFigureRef{Conformexampleconform} \cgalFigureBegin{Conformexampleconform,example-conform-Delaunay-Gabriel.png} -Initial triangulation and the corresponding Delaunay and Gabriel triangulation. -\cgalFigureEnd - -\cgalFigureBegin{ConformexampleconformDelaunay,example-conform-Delaunay.png} -The corresponding conforming Delaunay triangulation. +Initial triangulation and the corresponding conforming Delaunay and Gabriel triangulation. \cgalFigureEnd \section secMesh_2_meshes Meshes From 5ac03b991902b568a0a37271a69da10a6e9ceb15 Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Fri, 11 May 2018 10:22:37 +0100 Subject: [PATCH 05/17] PSP: Use \cgalCite --- Point_set_processing_3/include/CGAL/mst_orient_normals.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Point_set_processing_3/include/CGAL/mst_orient_normals.h b/Point_set_processing_3/include/CGAL/mst_orient_normals.h index b46e626e91f..f05ab4ffa17 100644 --- a/Point_set_processing_3/include/CGAL/mst_orient_normals.h +++ b/Point_set_processing_3/include/CGAL/mst_orient_normals.h @@ -501,7 +501,7 @@ create_mst_graph( /** \ingroup PkgPointSetProcessingAlgorithms Orients the normals of the range of `points` using the propagation - of a seed orientation through a minimum spanning tree of the Riemannian graph [Hoppe92]. + of a seed orientation through a minimum spanning tree of the Riemannian graph \cgalCite{cgal:hddms-srup-92}. This method modifies the order of input points so as to pack all sucessfully oriented points first, and returns an iterator over the first point with an unoriented normal (see erase-remove idiom). From 16e4cc5e4b6a6e0f951266ec2ba8121eea2718b7 Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Fri, 11 May 2018 14:42:30 +0100 Subject: [PATCH 06/17] Fix 2D Constrained Delaunay demo. The hint was outdated after cdt.clear() --- .../demo/Triangulation_2/TriangulationCircumcircle.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/GraphicsView/demo/Triangulation_2/TriangulationCircumcircle.h b/GraphicsView/demo/Triangulation_2/TriangulationCircumcircle.h index 59589cf1815..4a88e63a14d 100644 --- a/GraphicsView/demo/Triangulation_2/TriangulationCircumcircle.h +++ b/GraphicsView/demo/Triangulation_2/TriangulationCircumcircle.h @@ -33,6 +33,7 @@ protected: private: DT * dt; + typedef typename DT::Vertex_handle Vertex_handle; typename DT::Vertex_handle hint; typename DT::Face_handle fh; QGraphicsScene *scene_; @@ -89,8 +90,12 @@ TriangulationCircumcircle::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { if(dt->dimension() != 2){ circle->hide(); + hint = Vertex_handle(); return; } + if (hint == Vertex_handle()){ + hint = dt->infinite_vertex(); + } typename T::Point p = typename T::Point(event->scenePos().x(), event->scenePos().y()); fh = dt->locate(p, hint->face()); hint = fh->vertex(0); From 7e42e9f5a2c9705b2a4fc92bfae6e0047d084475 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Loriot?= Date: Fri, 11 May 2018 22:53:43 +0200 Subject: [PATCH 07/17] move citation to avoid line break in the brief. --- Point_set_processing_3/include/CGAL/mst_orient_normals.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Point_set_processing_3/include/CGAL/mst_orient_normals.h b/Point_set_processing_3/include/CGAL/mst_orient_normals.h index f05ab4ffa17..f441f209de9 100644 --- a/Point_set_processing_3/include/CGAL/mst_orient_normals.h +++ b/Point_set_processing_3/include/CGAL/mst_orient_normals.h @@ -501,11 +501,12 @@ create_mst_graph( /** \ingroup PkgPointSetProcessingAlgorithms Orients the normals of the range of `points` using the propagation - of a seed orientation through a minimum spanning tree of the Riemannian graph \cgalCite{cgal:hddms-srup-92}. - + of a seed orientation through a minimum spanning tree of the Riemannian graph. This method modifies the order of input points so as to pack all sucessfully oriented points first, and returns an iterator over the first point with an unoriented normal (see erase-remove idiom). For this reason it should not be called on sorted containers. + It is based on \cgalCite{cgal:hddms-srup-92}. + \warning This function may fail when Boost version 1.54 is used, because of the following bug: https://svn.boost.org/trac/boost/ticket/9012 From 0b505bb7466df3f9921d4b76b29def88f37fdce7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Loriot?= Date: Fri, 11 May 2018 23:04:39 +0200 Subject: [PATCH 08/17] remove unused figure --- .../doc/Mesh_2/fig/example-conform-Delaunay.png | Bin 4500 -> 0 bytes 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100644 Mesh_2/doc/Mesh_2/fig/example-conform-Delaunay.png diff --git a/Mesh_2/doc/Mesh_2/fig/example-conform-Delaunay.png b/Mesh_2/doc/Mesh_2/fig/example-conform-Delaunay.png deleted file mode 100644 index 580db6feb3df34ec63ab00365af75198bb121c15..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4500 zcmXX~3pkVQ8{f%c4$C%Q!jLeO5MquKO4jDkk|@$)v~rkH&P`KQ z7WHq=aqJb(Xrv{r^T7XX;$*=Z) zBBSbxGrx7%$LZUbsl-$TO1zz1Ys+GrjblpmHpJZ4gu?vgccaBl)pHa$B{21OZ+#Z7 zPhbR?f0eGDS3bs1Lxo(K^$9)fga|*GgQH~_jXqM7P~ubXtVoSjk(svHbS=LHjF*<4 zYSfl=qZjmfUgu=AXd7ZzHoan+z0ee+o1f*Xb<5#NlY4{N@oeKUTAoqC!SboFh(Lnb zn6%g^dSA^I{Ybo8PL}0%A5O-jncp$^m$Ro2Z}T*BV;0fzjvh}!0p|foN`m)TV^zIV z*@LWtD@K+#4tgn-to`EcWjo$_nM-iGf9|?kjLJ-Wmc{oSYlXspg08#sR}8vo$MZgr zjh1hm-KL#sPqVq@Icj`H>RZI1d#2BX0vl;2N{gfmb4t=_^8vMpb$aMT2_hBmcAO+{Q4gIW!P)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tY|S`#9uyrR zLW4K$=cehw98^NNX_jFpWkvTqzB)gb`}8jFWj;EN7d_>=D+(Hm32;FcB|V6QHXec2 zx^dHlux4|yEaC5L|E&AiG|QTeEL&PeK^x@bu> z2=ZyhtTQ*QTs{sJAsVWWYT5ni$DOhIBuU>}uv)~HqpdB?yWiz5`H*FgaVw7-Y&w$k z&6%IBMV2|n)#U)k+r_B&WqB{>`{?d)GEAr*@mFo8QN?<58-8XX`AODNAK;|(9N%bk zere9Aaa&4^UUVlz(FSAKy?8Tg3E2S?E?cjvd|D20TMg&wO+T4NMug~g&%C?3^aAcM zyUCZUo@SI^9l~!q>Vk~8g{IKmRy+5F*Z^JwP?X+#yRtJkacSfnBXYoGR;DtS7JbPG zP3p?ZRODI;n^BYmzwKiuAg01-Bqb!;V9ZOC8Tq?8o_8q`b4#h>Q#qdntbYOTras%P zK64MOHoe77{on3CX0`+3teg7s4ZX1@@avgB|Cmm6Qx{yY8QY7ciAM~(dAB2xsjENz z{Gm?gxO>&P?N9(z6AYFvUZ{tu@PN`(Lb From c2c2c1e4981c3dfef1c85a67d0dd2efa6e9a6326 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Loriot?= Date: Fri, 11 May 2018 23:06:40 +0200 Subject: [PATCH 09/17] improve phrasing --- Mesh_2/doc/Mesh_2/Mesh_2.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Mesh_2/doc/Mesh_2/Mesh_2.txt b/Mesh_2/doc/Mesh_2/Mesh_2.txt index 3ff3e3797f4..64012f69e97 100644 --- a/Mesh_2/doc/Mesh_2/Mesh_2.txt +++ b/Mesh_2/doc/Mesh_2/Mesh_2.txt @@ -98,7 +98,7 @@ printed. See \cgalFigureRef{Conformexampleconform} \cgalFigureBegin{Conformexampleconform,example-conform-Delaunay-Gabriel.png} -Initial triangulation and the corresponding conforming Delaunay and Gabriel triangulation. +From left to right: Initial Delaunay triangulation, the corresponding conforming Delaunay, and the corresponding Gabriel triangulation. \cgalFigureEnd \section secMesh_2_meshes Meshes From 5690cc4a0242f45eb855a36a0760738b91a97aea Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Wed, 2 May 2018 15:40:49 +0100 Subject: [PATCH 10/17] Arrangement_2: Add Forward Declaration --- .../include/CGAL/Surface_sweep_2/Arr_overlay_traits_2.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Arrangement_on_surface_2/include/CGAL/Surface_sweep_2/Arr_overlay_traits_2.h b/Arrangement_on_surface_2/include/CGAL/Surface_sweep_2/Arr_overlay_traits_2.h index 1ef10dcf3c9..6df312301ba 100644 --- a/Arrangement_on_surface_2/include/CGAL/Surface_sweep_2/Arr_overlay_traits_2.h +++ b/Arrangement_on_surface_2/include/CGAL/Surface_sweep_2/Arr_overlay_traits_2.h @@ -347,6 +347,9 @@ public: return os; } + class Parameter_space_in_x_2; + class Parameter_space_in_y_2; + /*! A functor that computes intersections between x-monotone curves. */ class Intersect_2 { protected: From 99bc374cce52f419118df8f4d0ff12b06b1aa7e1 Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Wed, 2 May 2018 16:17:47 +0100 Subject: [PATCH 11/17] More forward declarations --- Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d_1.h | 4 +++- .../include/CGAL/Arr_polycurve_traits_2.h | 3 +++ Polynomial/include/CGAL/Polynomial_traits_d.h | 8 +++----- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d_1.h b/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d_1.h index 905b6d8eba2..43505f07271 100644 --- a/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d_1.h +++ b/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d_1.h @@ -201,7 +201,9 @@ public: }; // class Algebraic_real_traits - + + class Construct_algebraic_real_1; + // Functors of Algebraic_kernel_d_1 struct Solve_1 { public: diff --git a/Arrangement_on_surface_2/include/CGAL/Arr_polycurve_traits_2.h b/Arrangement_on_surface_2/include/CGAL/Arr_polycurve_traits_2.h index 34c7931e702..ef0d6e94e4c 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arr_polycurve_traits_2.h +++ b/Arrangement_on_surface_2/include/CGAL/Arr_polycurve_traits_2.h @@ -163,6 +163,9 @@ public: /// \name Construction functors(based on the subcurve traits). //@{ +#ifndef DOXYGEN_RUNNING + class Push_back_2; +#endif /*! \class * A functor that divides an arc into x-monotone arcs. That are, arcs that * do not cross the identification arc. diff --git a/Polynomial/include/CGAL/Polynomial_traits_d.h b/Polynomial/include/CGAL/Polynomial_traits_d.h index 42c96b05c15..1c8b7f827af 100644 --- a/Polynomial/include/CGAL/Polynomial_traits_d.h +++ b/Polynomial/include/CGAL/Polynomial_traits_d.h @@ -729,7 +729,9 @@ public: return gic( gc( p, exponent ), ev ); }; }; - + + typedef CGAL::internal::Monomial_representation Monomial_representation; + // Swap variable x_i with x_j struct Swap { typedef Polynomial_d result_type; @@ -1537,10 +1539,6 @@ struct Construct_innermost_coefficient_const_iterator_range }; - typedef - CGAL::internal::Monomial_representation - Monomial_representation; - // returns the Exponten_vector of the innermost leading coefficient struct Degree_vector{ typedef Exponent_vector result_type; From b33ab791e1308414c3816eb33775bc41a46a09b4 Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Sat, 5 May 2018 15:03:06 +0100 Subject: [PATCH 12/17] Disable a warning. Fix an allocator call --- CGAL_Core/include/CGAL/CORE/CoreDefs.h | 3 +++ Installation/include/CGAL/disable_warnings.h | 1 + .../CGAL/Partition_2/Rotation_tree_2.h | 4 ++++ .../include/CGAL/Segment_tree_d.h | 19 ++++++++++++++++++- 4 files changed, 26 insertions(+), 1 deletion(-) diff --git a/CGAL_Core/include/CGAL/CORE/CoreDefs.h b/CGAL_Core/include/CGAL/CORE/CoreDefs.h index 90759e086fa..499d7b1dbf3 100644 --- a/CGAL_Core/include/CGAL/CORE/CoreDefs.h +++ b/CGAL_Core/include/CGAL/CORE/CoreDefs.h @@ -41,6 +41,7 @@ #include #include +#include #ifdef CGAL_HEADER_ONLY @@ -340,4 +341,6 @@ inline void setPositionalFormat(std::ostream& o = std::cout) { #include #endif // CGAL_HEADER_ONLY +#include + #endif // _CORE_COREDEFS_H_ diff --git a/Installation/include/CGAL/disable_warnings.h b/Installation/include/CGAL/disable_warnings.h index 6c180ab3514..587492aad9c 100644 --- a/Installation/include/CGAL/disable_warnings.h +++ b/Installation/include/CGAL/disable_warnings.h @@ -34,6 +34,7 @@ # pragma warning(disable: 4714) // function marked as __forceinline not inlined # pragma warning(disable: 4800) // forcing value to bool 'true' or 'false' (performance warning) # pragma warning(disable: 4913) // user defined binary operator ',' exists but no overload could convert all operands, default built-in binary operator ',' used +# pragma warning(disable: 4834) // discarding return value of function with 'nodiscard' attribute #endif diff --git a/Partition_2/include/CGAL/Partition_2/Rotation_tree_2.h b/Partition_2/include/CGAL/Partition_2/Rotation_tree_2.h index f9228e36d0b..a149a137f06 100644 --- a/Partition_2/include/CGAL/Partition_2/Rotation_tree_2.h +++ b/Partition_2/include/CGAL/Partition_2/Rotation_tree_2.h @@ -36,6 +36,8 @@ #ifndef CGAL_ROTATION_TREE_H #define CGAL_ROTATION_TREE_H +#include + #include @@ -178,6 +180,8 @@ private: #include +#include + #endif // CGAL_ROTATION_TREE_H // For the Emacs editor: diff --git a/SearchStructures/include/CGAL/Segment_tree_d.h b/SearchStructures/include/CGAL/Segment_tree_d.h index 1c0b6dafe39..625050bd1c5 100644 --- a/SearchStructures/include/CGAL/Segment_tree_d.h +++ b/SearchStructures/include/CGAL/Segment_tree_d.h @@ -107,7 +107,8 @@ protected: typedef Segment_tree_node Segment_tree_node_t; typedef Segment_tree_node *link_type; - std::allocator alloc; + typedef std::allocator allocator_type; + allocator_type alloc; C_Interface m_interface; bool is_built; @@ -197,7 +198,11 @@ protected: { Segment_tree_node_t node(l,r,kl,kr); Segment_tree_node_t* node_ptr = alloc.allocate(1); +#ifdef CGAL_CXX11 + std::allocator_traits::construct(alloc, node_ptr, node); +#else alloc.construct(node_ptr, node); +#endif return node_ptr; } @@ -205,7 +210,11 @@ protected: { Segment_tree_node_t node(kl,kr); Segment_tree_node_t* node_ptr = alloc.allocate(1); +#ifdef CGAL_CXX11 + std::allocator_traits::construct(alloc, node_ptr, node); +#else alloc.construct(node_ptr, node); +#endif return node_ptr; } @@ -213,7 +222,11 @@ protected: { Segment_tree_node_t node; Segment_tree_node_t* node_ptr = alloc.allocate(1); +#ifdef CGAL_CXX11 + std::allocator_traits::construct(alloc, node_ptr, node); +#else alloc.construct(node_ptr, node); +#endif return node_ptr; } @@ -298,7 +311,11 @@ protected: void delete_node(Segment_tree_node_t* node_ptr) { +#ifdef CGAL_CXX11 + std::allocator_traits::destroy(alloc, node_ptr); +#else alloc.destroy(node_ptr); +#endif alloc.deallocate(node_ptr,1); } From c65a07db7ea3d70ef0ba44a70eef0179266401cf Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Sat, 5 May 2018 18:48:34 +0100 Subject: [PATCH 13/17] Qualify local struct with class scope --- Minkowski_sum_2/include/CGAL/Minkowski_sum_2/AABB_traits_2.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Minkowski_sum_2/include/CGAL/Minkowski_sum_2/AABB_traits_2.h b/Minkowski_sum_2/include/CGAL/Minkowski_sum_2/AABB_traits_2.h index 7088fd1b83d..1eb99e9e72a 100644 --- a/Minkowski_sum_2/include/CGAL/Minkowski_sum_2/AABB_traits_2.h +++ b/Minkowski_sum_2/include/CGAL/Minkowski_sum_2/AABB_traits_2.h @@ -102,11 +102,11 @@ public: if (bbox.xmax()-bbox.xmin() >= bbox.ymax()-bbox.ymin()) { - std::nth_element(first, middle, beyond, less_x); // sort along x + std::nth_element(first, middle, beyond, AABB_traits_2::less_x); // sort along x } else { - std::nth_element(first, middle, beyond, less_y); // sort along y + std::nth_element(first, middle, beyond, AABB_traits_2::less_y); // sort along y } } }; From 654980580e72fdfba460e35e9f18a0865bd0b467 Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Mon, 7 May 2018 11:01:40 +0100 Subject: [PATCH 14/17] class -> struct --- Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d_1.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d_1.h b/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d_1.h index 43505f07271..c60e509abea 100644 --- a/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d_1.h +++ b/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d_1.h @@ -202,7 +202,7 @@ public: }; // class Algebraic_real_traits - class Construct_algebraic_real_1; + struct Construct_algebraic_real_1; // Functors of Algebraic_kernel_d_1 struct Solve_1 { From af9605a773b74bfdf8a33a21b6596328c5533c4a Mon Sep 17 00:00:00 2001 From: Maxime Gimeno Date: Fri, 4 May 2018 13:55:17 +0200 Subject: [PATCH 15/17] Make the dependencies check NOT order dependant. --- .../developer_scripts/cgal_check_dependencies.sh | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/Scripts/developer_scripts/cgal_check_dependencies.sh b/Scripts/developer_scripts/cgal_check_dependencies.sh index de3f26f48b7..d394e40f56d 100644 --- a/Scripts/developer_scripts/cgal_check_dependencies.sh +++ b/Scripts/developer_scripts/cgal_check_dependencies.sh @@ -28,19 +28,22 @@ do fi done -cmake -DCGAL_ENABLE_CHECK_HEADERS=TRUE -DDOXYGEN_EXECUTABLE="$DOX_PATH" -DCGAL_COPY_DEPENDENCIES=TRUE -DCMAKE_CXX_FLAGS="-std=c++11" .. +cmake -DCGAL_HEADER_ONLY=FALSE -DCGAL_ENABLE_CHECK_HEADERS=TRUE -DDOXYGEN_EXECUTABLE="$DOX_PATH" -DCGAL_COPY_DEPENDENCIES=TRUE -DCMAKE_CXX_FLAGS="-std=c++11" .. make -j$(nproc --all) packages_dependencies echo " Checks finished" for pkg_path in $CGAL_ROOT/* do pkg=$(basename $pkg_path) if [ -f "$pkg_path/package_info/$pkg/dependencies" ]; then - PKG_DIFF=$(diff -N -w "$pkg_path/package_info/$pkg/dependencies.old" "$pkg_path/package_info/$pkg/dependencies" || true) + PKG_DIFF=$(grep -Fxv -f "$pkg_path/package_info/$pkg/dependencies.old" "$pkg_path/package_info/$pkg/dependencies" || true) if [ -n "$PKG_DIFF" ]; then HAS_DIFF=TRUE - echo "Differences in $pkg: $PKG_DIFF" - else - echo "No differencies in $pkg dependencies." + echo "Differences in $pkg: $PKG_DIFF are new and not committed." + fi + PKG_DIFF=$(grep -Fxv -f "$pkg_path/package_info/$pkg/dependencies" "$pkg_path/package_info/$pkg/dependencies.old" || true) + if [ -n "$PKG_DIFF" ]; then + HAS_DIFF=TRUE + echo "Differences in $pkg: $PKG_DIFF have disappeared." fi if [ -f $pkg_path/package_info/$pkg/dependencies.old ]; then rm $pkg_path/package_info/$pkg/dependencies.old @@ -51,7 +54,8 @@ echo " Checks finished" cd $CGAL_ROOT rm -r dep_check_build if [ -n "$HAS_DIFF" ]; then - echo " You should run cmake with options CGAL_ENABLE_CHECK_HEADERS and CGAL_COPY_DEPENDENCIES ON, make the target packages_dependencies and commit the new dependencies files." + echo " You can run cmake with options CGAL_ENABLE_CHECK_HEADERS and CGAL_COPY_DEPENDENCIES ON, make the target packages_dependencies and commit the new dependencies files," + echo " or simply manually edit the problematic files." exit 1 else echo "The dependencies are up to date." From 0bf465dee602f88e22bd71025fe32c18b412609d Mon Sep 17 00:00:00 2001 From: Laurent Rineau Date: Tue, 15 May 2018 15:32:04 +0000 Subject: [PATCH 16/17] Fix indentation --- GraphicsView/demo/Triangulation_2/TriangulationCircumcircle.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/GraphicsView/demo/Triangulation_2/TriangulationCircumcircle.h b/GraphicsView/demo/Triangulation_2/TriangulationCircumcircle.h index 4a88e63a14d..dad56939a61 100644 --- a/GraphicsView/demo/Triangulation_2/TriangulationCircumcircle.h +++ b/GraphicsView/demo/Triangulation_2/TriangulationCircumcircle.h @@ -90,11 +90,11 @@ TriangulationCircumcircle::mouseMoveEvent(QGraphicsSceneMouseEvent *event) { if(dt->dimension() != 2){ circle->hide(); - hint = Vertex_handle(); + hint = Vertex_handle(); return; } if (hint == Vertex_handle()){ - hint = dt->infinite_vertex(); + hint = dt->infinite_vertex(); } typename T::Point p = typename T::Point(event->scenePos().x(), event->scenePos().y()); fh = dt->locate(p, hint->face()); From e24a089ae8250086afdca526c01f02523360743d Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Wed, 2 May 2018 15:19:45 +0100 Subject: [PATCH 17/17] The class std::iterator got deprecated. It only served to define some types --- .../CGAL/internal/boost/array_binary_tree.hpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/STL_Extension/include/CGAL/internal/boost/array_binary_tree.hpp b/STL_Extension/include/CGAL/internal/boost/array_binary_tree.hpp index ed646779099..dc9e8a6b4e5 100644 --- a/STL_Extension/include/CGAL/internal/boost/array_binary_tree.hpp +++ b/STL_Extension/include/CGAL/internal/boost/array_binary_tree.hpp @@ -20,7 +20,7 @@ #ifndef CGAL_INTERNAL_ARRAY_BINARY_TREE_HPP #define CGAL_INTERNAL_ARRAY_BINARY_TREE_HPP -#include +#include #include #include @@ -52,12 +52,12 @@ public: struct children_type { struct iterator - : ::boost::iterator { // replace with iterator_adaptor implementation -JGS + typedef std::forward_iterator_tag Category; + typedef ArrayBinaryTreeNode value_type; + typedef size_type difference_type + typedef ArrayBinaryTreeNode* Pointer; + typedef ArrayBinaryTreeNode& Reference; inline iterator() : i(0), n(0) { } inline iterator(const iterator& x) : r(x.r), i(x.i), n(x.n), id(x.id) { }