diff --git a/.github/workflows/reuse.yml b/.github/workflows/reuse.yml new file mode 100644 index 00000000000..2113372a877 --- /dev/null +++ b/.github/workflows/reuse.yml @@ -0,0 +1,35 @@ +# SPDX-FileCopyrightText: 2020 Free Software Foundation Europe e.V. +# +# SPDX-License-Identifier: GPL-3.0-or-later + +name: REUSE Compliance Check + +on: [push, pull_request] + +jobs: + reuse: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: REUSE version + uses: fsfe/reuse-action@v1 + with: + args: --version + - name: REUSE lint + uses: fsfe/reuse-action@v1 + with: + args: --include-submodules lint + - name: REUSE SPDX SBOM + uses: fsfe/reuse-action@v1 + with: + args: spdx + - name: install dependencies + run: sudo apt-get install -y cmake + - name: Create CGAL internal release + run: | + mkdir -p ./release + cmake -DDESTINATION=./release -DCGAL_VERSION=9.9 -P ./Scripts/developer_scripts/cgal_create_release_with_cmake.cmake + - name: REUSE lint release tarball + uses: fsfe/reuse-action@v1 + with: + args: --root ./release/CGAL-9.9 --include-submodules lint diff --git a/.reuse/dep5 b/.reuse/dep5 new file mode 100644 index 00000000000..06784d71d6b --- /dev/null +++ b/.reuse/dep5 @@ -0,0 +1,12 @@ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: CGAL +Upstream-Contact: CGAL Editorial Board +Source: https://github.com/CGAL/cgal + +Files: .* *.cmake *.md .github/* Maintenance/* */TODO */doc/* */deb/* */applications/* */doc_html/* */scripts/* */developer_scripts/* */demo/* */examples/* */src/* */test/* */benchmarks/* */benchmark/* */package_info/* */data/* */cmake/* +Copyright: 1995-2023 The CGAL Project +License: CC0-1.0 + +Files: CMakeLists.txt GraphicsView/include/CGAL/Qt/ImageInterface.ui GraphicsView/include/CGAL/Qt/resources/qglviewer-icon.xpm Installation/AUTHORS Installation/CMakeLists.txt Installation/README Installation/auxiliary/cgal_create_cmake_script.1 Installation/auxiliary/gmp/README Installation/include/CGAL/license/gpl_package_list.txt MacOSX/auxiliary/cgal_app.icns copyright +Copyright: 1995-2023 The CGAL Project +License: CC0-1.0 diff --git a/AABB_tree/include/CGAL/AABB_halfedge_graph_segment_primitive.h b/AABB_tree/include/CGAL/AABB_halfedge_graph_segment_primitive.h index 9a673026409..62484d59653 100644 --- a/AABB_tree/include/CGAL/AABB_halfedge_graph_segment_primitive.h +++ b/AABB_tree/include/CGAL/AABB_halfedge_graph_segment_primitive.h @@ -24,7 +24,6 @@ #include #include #include -#include #include #include @@ -34,7 +33,7 @@ namespace CGAL { /*! * \ingroup PkgAABBTreeRef - * Primitive type for a edge of a polyhedral surface. + * Primitive type for an edge of a polyhedral surface. * It wraps an `edge_descriptor` into a 3D segment. * The class model of `HalfedgeGraph` from which the primitive is built should not be deleted * while the AABB tree holding the primitive is in use. diff --git a/AABB_tree/include/CGAL/AABB_tree.h b/AABB_tree/include/CGAL/AABB_tree.h index 0016d4ecc09..1bc5173cb24 100644 --- a/AABB_tree/include/CGAL/AABB_tree.h +++ b/AABB_tree/include/CGAL/AABB_tree.h @@ -27,7 +27,6 @@ #include #include #include -#include #ifdef CGAL_HAS_THREADS #include @@ -143,7 +142,7 @@ namespace CGAL { /// An explicit call to `build()` must be made to ensure that the next call to /// a query function will not trigger the construction of the data structure. /// A call to `AABBTraits::set_shared_data(t...)` is made using the internally stored traits. - /// This procedure has a complexity of \f$O(n log(n))\f$, where \f$n\f$ is the number of + /// This procedure has a complexity of \cgalBigO{n log(n)}, where \f$n\f$ is the number of /// primitives of the tree. template void build(T&& ...); @@ -326,7 +325,7 @@ public: boost::optional< typename Intersection_and_primitive_id::Type > first_intersection(const Ray& query) const { - return first_intersection(query, boost::lambda::constant(false)); + return first_intersection(query, [](Primitive_id){ return false; }); } /// \endcond @@ -351,7 +350,7 @@ public: boost::optional first_intersected_primitive(const Ray& query) const { - return first_intersected_primitive(query, boost::lambda::constant(false)); + return first_intersected_primitive(query, [](Primitive_id){ return false; }); } /// \endcond ///@} diff --git a/AABB_tree/include/CGAL/AABB_tree/internal/AABB_ray_intersection.h b/AABB_tree/include/CGAL/AABB_tree/internal/AABB_ray_intersection.h index e738302d533..87ebbe012ab 100644 --- a/AABB_tree/include/CGAL/AABB_tree/internal/AABB_ray_intersection.h +++ b/AABB_tree/include/CGAL/AABB_tree/internal/AABB_ray_intersection.h @@ -201,7 +201,7 @@ template boost::optional< typename AABB_tree::template Intersection_and_primitive_id::Type > AABB_tree::first_intersection(const Ray& query, const SkipFunctor& skip) const { - CGAL_static_assertion_msg((std::is_same::value), + static_assert(std::is_same::value, "Ray and Ray_3 must be the same type"); switch(size()) // copy-paste from AABB_tree::traversal diff --git a/AABB_tree/test/AABB_tree/aabb_test_is_ray_intersection_geomtraits.cpp b/AABB_tree/test/AABB_tree/aabb_test_is_ray_intersection_geomtraits.cpp index c7198fe98e0..35612dc8ded 100644 --- a/AABB_tree/test/AABB_tree/aabb_test_is_ray_intersection_geomtraits.cpp +++ b/AABB_tree/test/AABB_tree/aabb_test_is_ray_intersection_geomtraits.cpp @@ -26,16 +26,16 @@ int main() { using namespace CGAL::internal::AABB_tree; - CGAL_static_assertion_msg( + static_assert( (Is_ray_intersection_geomtraits::value), "CGAL::Epeck should be a RayIntersectionGeomTraits"); - CGAL_static_assertion_msg( + static_assert( (Is_ray_intersection_geomtraits< CGAL::Simple_cartesian >::value), "CGAL::Epeck should be a RayIntersectionGeomTraits"); - CGAL_static_assertion_msg( + static_assert( (!Is_ray_intersection_geomtraits::value), "Pure AABBGeomTraits shouldn't be a RayIntersectionGeomTraits"); - CGAL_static_assertion_msg( + static_assert( (!Is_ray_intersection_geomtraits::value), "The empty struct shouldn't be a RayIntersectionGeomTraits"); diff --git a/AABB_tree/test/AABB_tree/aabb_test_multi_mesh.cpp b/AABB_tree/test/AABB_tree/aabb_test_multi_mesh.cpp index 5b78ff33016..3b2307a134b 100644 --- a/AABB_tree/test/AABB_tree/aabb_test_multi_mesh.cpp +++ b/AABB_tree/test/AABB_tree/aabb_test_multi_mesh.cpp @@ -3,7 +3,6 @@ #include #include -#include #include #include diff --git a/AABB_tree/test/AABB_tree/aabb_test_ray_intersection.cpp b/AABB_tree/test/AABB_tree/aabb_test_ray_intersection.cpp index 4e86ed22d7f..649f594d7e9 100644 --- a/AABB_tree/test/AABB_tree/aabb_test_ray_intersection.cpp +++ b/AABB_tree/test/AABB_tree/aabb_test_ray_intersection.cpp @@ -3,7 +3,6 @@ #include #include -#include #include #include @@ -92,7 +91,7 @@ int main() Vector bbox_center((bbox.xmin() + bbox.xmax()) / 2, (bbox.ymin() + bbox.ymax()) / 2, (bbox.zmin() + bbox.zmax()) / 2); - boost::array extents; + std::array extents; extents[0] = bbox.xmax() - bbox.xmin(); extents[1] = bbox.ymax() - bbox.ymin(); extents[2] = bbox.zmax() - bbox.zmin(); diff --git a/Algebraic_foundations/examples/Algebraic_foundations/fraction_traits.cpp b/Algebraic_foundations/examples/Algebraic_foundations/fraction_traits.cpp index 1bd5f4bd02a..4ecbef7420c 100644 --- a/Algebraic_foundations/examples/Algebraic_foundations/fraction_traits.cpp +++ b/Algebraic_foundations/examples/Algebraic_foundations/fraction_traits.cpp @@ -9,8 +9,8 @@ int main(){ typedef FT::Numerator_type Numerator_type; typedef FT::Denominator_type Denominator_type; - CGAL_static_assertion((std::is_same::value)); - CGAL_static_assertion((std::is_same::value)); + static_assert(std::is_same::value); + static_assert(std::is_same::value); Numerator_type numerator; Denominator_type denominator; diff --git a/Algebraic_foundations/examples/Algebraic_foundations/interoperable.cpp b/Algebraic_foundations/examples/Algebraic_foundations/interoperable.cpp index abf8265a837..e85c2e8d73b 100644 --- a/Algebraic_foundations/examples/Algebraic_foundations/interoperable.cpp +++ b/Algebraic_foundations/examples/Algebraic_foundations/interoperable.cpp @@ -9,7 +9,7 @@ binary_func(const A& a , const B& b){ typedef CGAL::Coercion_traits CT; // check for explicit interoperability - CGAL_static_assertion((CT::Are_explicit_interoperable::value)); + static_assert(CT::Are_explicit_interoperable::value); // CT::Cast is used to to convert both types into the coercion type typename CT::Cast cast; diff --git a/Algebraic_foundations/include/CGAL/Algebraic_structure_traits.h b/Algebraic_foundations/include/CGAL/Algebraic_structure_traits.h index cdfca730976..e0d5eee6706 100644 --- a/Algebraic_foundations/include/CGAL/Algebraic_structure_traits.h +++ b/Algebraic_foundations/include/CGAL/Algebraic_structure_traits.h @@ -353,8 +353,7 @@ class Algebraic_structure_traits_base< Type_, typedef Coercion_traits< NT1, NT2 > CT; typedef typename CT::Type Coercion_type_NT1_NT2; CGAL_USE_TYPE(Coercion_type_NT1_NT2); - CGAL_static_assertion(( - ::std::is_same::value)); + static_assert(::std::is_same::value); typename Coercion_traits< NT1, NT2 >::Cast cast; operator()( cast(x), cast(y), q, r ); diff --git a/Algebraic_foundations/include/CGAL/Coercion_traits.h b/Algebraic_foundations/include/CGAL/Coercion_traits.h index 14acb431c7c..f6c9092dec6 100644 --- a/Algebraic_foundations/include/CGAL/Coercion_traits.h +++ b/Algebraic_foundations/include/CGAL/Coercion_traits.h @@ -35,9 +35,9 @@ #define CGAL_IMPLICIT_INTEROPERABLE_BINARY_OPERATOR_WITH_RT( NT, Result_type ) \ template < class CT_Type_1, class CT_Type_2 > \ Result_type operator()( const CT_Type_1& x, const CT_Type_2& y ) const { \ - CGAL_static_assertion((::std::is_same< \ + static_assert(::std::is_same< \ typename Coercion_traits< CT_Type_1, CT_Type_2 >::Type, NT \ - >::value)); \ + >::value) ; \ \ typename Coercion_traits< CT_Type_1, CT_Type_2 >::Cast cast; \ return operator()( cast(x), cast(y) ); \ diff --git a/Algebraic_foundations/include/CGAL/Scalar_factor_traits.h b/Algebraic_foundations/include/CGAL/Scalar_factor_traits.h index db6b3df845d..5453868a132 100644 --- a/Algebraic_foundations/include/CGAL/Scalar_factor_traits.h +++ b/Algebraic_foundations/include/CGAL/Scalar_factor_traits.h @@ -85,13 +85,13 @@ public: // determine extractable scalar factor Scalar operator () (const NT& a) { - CGAL_static_assertion(( ::std::is_same< NT,Scalar >::value)); + static_assert(::std::is_same< NT,Scalar >::value); typedef typename Algebraic_structure_traits::Algebraic_category SAT; return scalar_factor(a, SAT()); } // determine extractable scalar factor Scalar operator () (const NT& a, const Scalar& d) { - CGAL_static_assertion(( ::std::is_same< NT,Scalar >::value)); + static_assert(::std::is_same< NT,Scalar >::value); typedef typename Algebraic_structure_traits::Algebraic_category SAT; return scalar_factor(a,d,SAT()); } diff --git a/Algebraic_foundations/include/CGAL/Test/_test_algebraic_structure.h b/Algebraic_foundations/include/CGAL/Test/_test_algebraic_structure.h index 5a5e23c7d8f..56c421eee1f 100644 --- a/Algebraic_foundations/include/CGAL/Test/_test_algebraic_structure.h +++ b/Algebraic_foundations/include/CGAL/Test/_test_algebraic_structure.h @@ -44,7 +44,7 @@ template void check_result_type(AdaptableFunctor, ResultType){ typedef typename AdaptableFunctor::result_type result_type; - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); CGAL_USE_TYPE(result_type); } // check nothing for CGAL::Null_functor @@ -122,12 +122,11 @@ void test_algebraic_structure_intern( const CGAL::Integral_domain_tag& ) { CGAL_SNAP_AST_FUNCTORS(AST); using CGAL::Null_functor; - CGAL_static_assertion( - (!::std::is_same< Integral_division, Null_functor >::value)); - CGAL_static_assertion((!::std::is_same< Divides, Null_functor >::value)); - CGAL_static_assertion((!::std::is_same< Is_zero, Null_functor >::value)); - CGAL_static_assertion((!::std::is_same< Is_one, Null_functor >::value)); - CGAL_static_assertion((!::std::is_same< Square, Null_functor >::value)); + static_assert(!::std::is_same< Integral_division, Null_functor >::value); + static_assert(!::std::is_same< Divides, Null_functor >::value); + static_assert(!::std::is_same< Is_zero, Null_functor >::value); + static_assert(!::std::is_same< Is_one, Null_functor >::value); + static_assert(!::std::is_same< Square, Null_functor >::value); // functor const Is_zero is_zero = Is_zero(); @@ -206,7 +205,7 @@ void test_algebraic_structure_intern( CGAL_SNAP_AST_FUNCTORS(AST); using CGAL::Null_functor; - CGAL_static_assertion((!::std::is_same< Gcd, Null_functor>::value)); + static_assert(!::std::is_same< Gcd, Null_functor>::value); const Gcd gcd = Gcd(); assert( gcd( AS ( 0), AS ( 0)) == unit_normal( AS (0) ) ); @@ -268,9 +267,9 @@ void test_algebraic_structure_intern( const CGAL::Euclidean_ring_tag&) { CGAL_SNAP_AST_FUNCTORS(AST); using CGAL::Null_functor; - CGAL_static_assertion((!::std::is_same< Div, Null_functor>::value)); - CGAL_static_assertion((!::std::is_same< Mod, Null_functor>::value)); - CGAL_static_assertion((!::std::is_same< Div_mod, Null_functor>::value)); + static_assert(!::std::is_same< Div, Null_functor>::value); + static_assert(!::std::is_same< Mod, Null_functor>::value); + static_assert(!::std::is_same< Div_mod, Null_functor>::value); const Div div=Div(); const Mod mod=Mod(); @@ -387,7 +386,7 @@ void test_algebraic_structure_intern( const CGAL::Field_with_sqrt_tag& ) { CGAL_SNAP_AST_FUNCTORS(AST); - CGAL_static_assertion((!::std::is_same< Sqrt, Null_functor>::value)); + static_assert(!::std::is_same< Sqrt, Null_functor>::value); const Sqrt sqrt =Sqrt(); AS a(4); @@ -613,11 +612,9 @@ class Test_is_square { CGAL_USE_TYPE(First_argument_type); CGAL_USE_TYPE(Second_argument_type); - CGAL_static_assertion( - ( ::std::is_same< AS , First_argument_type>::value)); - CGAL_static_assertion( - ( ::std::is_same< AS& , Second_argument_type>::value)); - //CGAL_static_assertion(( ::std::is_same< bool , Result_type>::value)); + static_assert(::std::is_same< AS , First_argument_type>::value); + static_assert(::std::is_same< AS& , Second_argument_type>::value); + //static_assert(::std::is_same< bool , Result_type>::value); bool b = Result_type(true); CGAL_USE(b); AS test_number = AS(3)*AS(3); @@ -649,8 +646,8 @@ public: typedef typename Sqrt::result_type Result_type; CGAL_USE_TYPE(Argument_type); CGAL_USE_TYPE(Result_type); - CGAL_static_assertion(( ::std::is_same< AS , Argument_type>::value)); - CGAL_static_assertion(( ::std::is_same< AS , Result_type>::value)); + static_assert(::std::is_same< AS , Argument_type>::value); + static_assert(::std::is_same< AS , Result_type>::value); typedef Algebraic_structure_traits AST; typedef typename AST::Is_exact Is_exact; assert( !Is_exact::value || AS (3) == sqrt( AS (9))); @@ -675,12 +672,9 @@ public: CGAL_USE_TYPE(First_argument_type); CGAL_USE_TYPE(Second_argument_type); CGAL_USE_TYPE(Result_type); - CGAL_static_assertion( - ( ::std::is_same::value)); - CGAL_static_assertion( - ( ::std::is_same< AS , Second_argument_type>::value)); - CGAL_static_assertion( - ( ::std::is_same< AS , Result_type>::value)); + static_assert(::std::is_same::value); + static_assert(::std::is_same< AS , Second_argument_type>::value); + static_assert(::std::is_same< AS , Result_type>::value); AS epsilon(1); assert( test_equality_epsilon( AS (2), root( 4, AS (16) ), epsilon ) ); @@ -803,7 +797,7 @@ void test_algebraic_structure(){ typedef CGAL::Algebraic_structure_traits< AS > AST; CGAL_SNAP_AST_FUNCTORS(AST); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef typename AST::Boolean Boolean; assert(!Boolean()); @@ -816,14 +810,13 @@ void test_algebraic_structure(){ using CGAL::Integral_domain_without_division_tag; using CGAL::Null_functor; // Test for desired exactness - CGAL_static_assertion( - ( ::std::is_same< typename AST::Is_exact, Is_exact >::value)); + static_assert(::std::is_same< typename AST::Is_exact, Is_exact >::value); + static_assert(::std::is_convertible< Tag, + Integral_domain_without_division_tag >::value ); + static_assert(::std::is_same< Tag, Algebraic_category>::value); + static_assert(!::std::is_same< Simplify, Null_functor>::value); + static_assert(!::std::is_same< Unit_part, Null_functor>::value); - CGAL_static_assertion(( ::boost::is_convertible< Tag, - Integral_domain_without_division_tag >::value )); - CGAL_static_assertion(( ::std::is_same< Tag, Algebraic_category>::value)); - CGAL_static_assertion((!::std::is_same< Simplify, Null_functor>::value)); - CGAL_static_assertion((!::std::is_same< Unit_part, Null_functor>::value)); const Simplify simplify=Simplify();; const Unit_part unit_part= Unit_part(); @@ -943,8 +936,7 @@ void test_algebraic_structure( const AS & a, const AS & b, const AS & c) { typedef CGAL::Algebraic_structure_traits AST; typedef typename AST::Is_numerical_sensitive Is_numerical_sensitive; - CGAL_static_assertion( - !(::std::is_same::value)); + static_assert(!::std::is_same::value); CGAL_USE_TYPE(Is_numerical_sensitive); } diff --git a/Algebraic_foundations/include/CGAL/Test/_test_coercion_traits.h b/Algebraic_foundations/include/CGAL/Test/_test_coercion_traits.h index 0caa6ced04e..cff190a023d 100644 --- a/Algebraic_foundations/include/CGAL/Test/_test_coercion_traits.h +++ b/Algebraic_foundations/include/CGAL/Test/_test_coercion_traits.h @@ -326,7 +326,7 @@ void test_implicit_interoperable_one_way() { typedef typename CT::Type C; typedef typename CT::Are_implicit_interoperable Are_implicit_interoperable; - CGAL_static_assertion( + static_assert( (::std::is_same::value)); assert((::std::is_same::value)); @@ -346,9 +346,9 @@ void test_explicit_interoperable_one_way(){ typedef typename CT::Cast Cast; typedef typename Cast::result_type result_type; CGAL_USE_TYPE(result_type); - CGAL_static_assertion((::std::is_same::value)); - CGAL_static_assertion((::std::is_same< typename CT::Are_explicit_interoperable,CGAL::Tag_true>::value)); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); + static_assert(::std::is_same< typename CT::Are_explicit_interoperable,CGAL::Tag_true>::value); + static_assert(::std::is_same::value); typename CT::Cast cast; A a(3); diff --git a/Algebraic_foundations/include/CGAL/Test/_test_fraction_traits.h b/Algebraic_foundations/include/CGAL/Test/_test_fraction_traits.h index e1aa91eb29d..6d11b6f2c55 100644 --- a/Algebraic_foundations/include/CGAL/Test/_test_fraction_traits.h +++ b/Algebraic_foundations/include/CGAL/Test/_test_fraction_traits.h @@ -37,11 +37,11 @@ void test_fraction_traits(){ typedef typename FT::Compose Compose; CGAL_USE_TYPE(Is_fraction); - CGAL_static_assertion( (::std::is_same::value)); - CGAL_static_assertion( (::std::is_same::value)); - CGAL_static_assertion(!(::std::is_same::value)); - CGAL_static_assertion(!(::std::is_same::value)); - CGAL_static_assertion(!(::std::is_same::value)); + static_assert(::std::is_same::value); + static_assert(::std::is_same::value); + static_assert(!::std::is_same::value); + static_assert(!::std::is_same::value); + static_assert(!::std::is_same::value); // Decompose diff --git a/Algebraic_foundations/include/CGAL/Test/_test_rational_traits.h b/Algebraic_foundations/include/CGAL/Test/_test_rational_traits.h index 5efda40bc2f..68e648e69c5 100644 --- a/Algebraic_foundations/include/CGAL/Test/_test_rational_traits.h +++ b/Algebraic_foundations/include/CGAL/Test/_test_rational_traits.h @@ -29,7 +29,7 @@ void test_rational_traits(){ typedef Rational_traits Rational_traits; typedef typename Rational_traits::RT RT; - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); assert( Rational_traits().numerator(x) == RT(7)); assert( Rational_traits().denominator(x) == RT(2)); diff --git a/Algebraic_foundations/include/CGAL/Test/_test_real_embeddable.h b/Algebraic_foundations/include/CGAL/Test/_test_real_embeddable.h index bb67e3f57a5..fbe5b66132b 100644 --- a/Algebraic_foundations/include/CGAL/Test/_test_real_embeddable.h +++ b/Algebraic_foundations/include/CGAL/Test/_test_real_embeddable.h @@ -48,9 +48,9 @@ namespace CGAL { void operator() (const ToDouble& to_double) { typedef typename ToDouble::argument_type Argument_type; typedef typename ToDouble::result_type Result_type; - CGAL_static_assertion(( ::std::is_same::value)); + static_assert( ::std::is_same::value); CGAL_USE_TYPE(Argument_type); - CGAL_static_assertion(( ::std::is_same::value)); + static_assert( ::std::is_same::value); CGAL_USE_TYPE(Result_type); assert(42.0 == to_double(Type(42))); } @@ -71,9 +71,9 @@ namespace CGAL { typedef typename To_interval::argument_type Argument_type; typedef typename To_interval::result_type Result_type; typedef std::pair Interval_type; - CGAL_static_assertion(( ::std::is_same::value)); + static_assert( ::std::is_same::value); CGAL_USE_TYPE(Argument_type); - CGAL_static_assertion(( ::std::is_same::value)); + static_assert( ::std::is_same::value); CGAL_USE_TYPE(Result_type); CGAL_USE_TYPE(Interval_type); // assert(NiX::in(42.0,to_Interval(Type(42)))); @@ -139,7 +139,7 @@ void test_real_embeddable() { CGAL_SNAP_RET_FUNCTORS(RET); typedef typename RET::Is_real_embeddable Is_real_embeddable; using CGAL::Tag_true; - CGAL_static_assertion(( ::std::is_same< Is_real_embeddable, Tag_true>::value)); + static_assert(::std::is_same< Is_real_embeddable, Tag_true>::value); CGAL_USE_TYPE(Is_real_embeddable); typedef typename RET::Boolean Boolean; @@ -246,7 +246,7 @@ void test_not_real_embeddable() { typedef CGAL::Real_embeddable_traits RET; typedef typename RET::Is_real_embeddable Is_real_embeddable; using CGAL::Tag_false; - CGAL_static_assertion(( ::std::is_same< Is_real_embeddable, Tag_false>::value)); + static_assert(::std::is_same< Is_real_embeddable, Tag_false>::value); CGAL_USE_TYPE(Is_real_embeddable); } @@ -254,13 +254,13 @@ void test_not_real_embeddable() { //template //void test_rounded_log2_abs(Type zero, CGAL::Null_functor, CeilLog2Abs) { // typedef CGAL::Null_functor Null_functor; -// CGAL_static_assertion(( ::std::is_same< CeilLog2Abs, Null_functor>::value)); +// static_assert(::std::is_same< CeilLog2Abs, Null_functor>::value); //} // //template //void test_rounded_log2_abs(Type zero, FloorLog2Abs fl_log, CeilLog2Abs cl_log) { // typedef CGAL::Null_functor Null_functor; -// CGAL_static_assertion((!::std::is_same< CeilLog2Abs, Null_functor>::value)); +// static_assert(!::std::is_same< CeilLog2Abs, Null_functor>::value); // // assert( fl_log(Type( 7)) == 2 ); // assert( cl_log(Type( 7)) == 3 ); diff --git a/Algebraic_foundations/test/Algebraic_foundations/Algebraic_extension_traits.cpp b/Algebraic_foundations/test/Algebraic_foundations/Algebraic_extension_traits.cpp index 87e5235cfe1..95c89235190 100644 --- a/Algebraic_foundations/test/Algebraic_foundations/Algebraic_extension_traits.cpp +++ b/Algebraic_foundations/test/Algebraic_foundations/Algebraic_extension_traits.cpp @@ -9,21 +9,21 @@ int main(){ typedef AET::Type Type; CGAL_USE_TYPE(Type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef AET::Is_extended Is_extended; CGAL_USE_TYPE(Is_extended); - CGAL_static_assertion( + static_assert( (::std::is_same::value)); typedef AET::Normalization_factor Normalization_factor; { typedef Normalization_factor::argument_type argument_type; CGAL_USE_TYPE(argument_type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef Normalization_factor::result_type result_type; CGAL_USE_TYPE(result_type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); Normalization_factor nfac; assert(nfac(3)==1); } @@ -31,10 +31,10 @@ int main(){ { typedef DFAI::argument_type argument_type; CGAL_USE_TYPE(argument_type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef DFAI::result_type result_type; CGAL_USE_TYPE(result_type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); DFAI dfai; assert(dfai(3)==1); } @@ -45,21 +45,21 @@ int main(){ typedef AET::Type Type; CGAL_USE_TYPE(Type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef AET::Is_extended Is_extended; CGAL_USE_TYPE(Is_extended); - CGAL_static_assertion( + static_assert( (::std::is_same::value)); typedef AET::Normalization_factor Normalization_factor; { typedef Normalization_factor::argument_type argument_type; CGAL_USE_TYPE(argument_type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef Normalization_factor::result_type result_type; CGAL_USE_TYPE(result_type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); Normalization_factor nfac; assert(nfac(EXT(3))==1); assert(nfac(EXT(3,0,5))==1); @@ -69,10 +69,10 @@ int main(){ { typedef DFAI::argument_type argument_type; CGAL_USE_TYPE(argument_type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef DFAI::result_type result_type; CGAL_USE_TYPE(result_type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); DFAI dfai; assert(dfai(EXT(3))==1); assert(dfai(EXT(3,0,5))==1); diff --git a/Algebraic_foundations/test/Algebraic_foundations/Algebraic_structure_traits.cpp b/Algebraic_foundations/test/Algebraic_foundations/Algebraic_structure_traits.cpp index bc1e4b85bb0..efd31636c51 100644 --- a/Algebraic_foundations/test/Algebraic_foundations/Algebraic_structure_traits.cpp +++ b/Algebraic_foundations/test/Algebraic_foundations/Algebraic_structure_traits.cpp @@ -7,7 +7,7 @@ { \ typedef AST::NAME NAME; \ CGAL_USE_TYPE(NAME); \ - CGAL_static_assertion( \ + static_assert( \ (::std::is_same::value)); \ } @@ -16,19 +16,19 @@ int main(){ typedef AST::Type Type; CGAL_USE_TYPE(Type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef AST::Algebraic_category Algebraic_category; CGAL_USE_TYPE(Algebraic_category); - CGAL_static_assertion( + static_assert( (::std::is_same::value)); typedef AST::Is_exact Is_exact; CGAL_USE_TYPE(Is_exact); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef AST::Is_numerical_sensitive Is_sensitive; CGAL_USE_TYPE(Is_sensitive); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); CGAL_IS_AST_NULL_FUNCTOR ( Simplify); CGAL_IS_AST_NULL_FUNCTOR ( Unit_part); diff --git a/Algebraic_foundations/test/Algebraic_foundations/Coercion_traits.cpp b/Algebraic_foundations/test/Algebraic_foundations/Coercion_traits.cpp index 7deecf693cc..a0ec9d741a4 100644 --- a/Algebraic_foundations/test/Algebraic_foundations/Coercion_traits.cpp +++ b/Algebraic_foundations/test/Algebraic_foundations/Coercion_traits.cpp @@ -6,22 +6,17 @@ int main(){ { typedef CGAL::Coercion_traits CT; CGAL_USE_TYPE(CT); - CGAL_static_assertion(( std::is_same::value)); - CGAL_static_assertion( - ( std::is_same::value)); - CGAL_static_assertion( - ( std::is_same::value)); + static_assert( std::is_same::value); + static_assert( std::is_same::value); + static_assert( std::is_same::value); assert( 5 == CT::Cast()(5)); } { typedef CGAL::Coercion_traits CT; CGAL_USE_TYPE(CT); -// CGAL_static_assertion(( std::is_same::value)); - CGAL_static_assertion( - ( std::is_same::value)); - CGAL_static_assertion( - ( std::is_same::value)); - CGAL_static_assertion( - ( std::is_same::value)); +// static_assert( std::is_same::value); + static_assert(std::is_same::value); + static_assert(std::is_same::value); + static_assert(std::is_same::value); } } diff --git a/Algebraic_foundations/test/Algebraic_foundations/Real_embeddable_traits.cpp b/Algebraic_foundations/test/Algebraic_foundations/Real_embeddable_traits.cpp index f9288c9eefd..f215c848458 100644 --- a/Algebraic_foundations/test/Algebraic_foundations/Real_embeddable_traits.cpp +++ b/Algebraic_foundations/test/Algebraic_foundations/Real_embeddable_traits.cpp @@ -7,7 +7,7 @@ { \ typedef RET::NAME NAME; \ CGAL_USE_TYPE(NAME); \ - CGAL_static_assertion( \ + static_assert( \ (::std::is_same::value)); \ } @@ -16,11 +16,11 @@ int main(){ typedef RET::Type Type; CGAL_USE_TYPE(Type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef RET::Is_real_embeddable Is_real_embeddable; CGAL_USE_TYPE(Is_real_embeddable); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); CGAL_IS_RET_NULL_FUNCTOR(Abs); CGAL_IS_RET_NULL_FUNCTOR(Sgn); diff --git a/Algebraic_foundations/test/Algebraic_foundations/Scalar_factor_traits.cpp b/Algebraic_foundations/test/Algebraic_foundations/Scalar_factor_traits.cpp index b2b6ffd0bf3..1fe2fcf620d 100644 --- a/Algebraic_foundations/test/Algebraic_foundations/Scalar_factor_traits.cpp +++ b/Algebraic_foundations/test/Algebraic_foundations/Scalar_factor_traits.cpp @@ -7,33 +7,31 @@ int main(){ typedef CGAL::Scalar_factor_traits SFT; CGAL_USE_TYPE(SFT); - CGAL_static_assertion((::std::is_same::value)); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); + static_assert(::std::is_same::value); typedef SFT::Scalar_factor Scalar_factor; { typedef Scalar_factor::result_type result_type; CGAL_USE_TYPE(result_type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef Scalar_factor::argument_type argument_type; CGAL_USE_TYPE(argument_type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); } typedef SFT::Scalar_div Scalar_div; { typedef Scalar_div::result_type result_type; CGAL_USE_TYPE(result_type); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef Scalar_div::first_argument_type first_argument_type; CGAL_USE_TYPE(first_argument_type); - CGAL_static_assertion( - (::std::is_same::value)); + static_assert(::std::is_same::value); typedef Scalar_div::second_argument_type second_argument_type; CGAL_USE_TYPE(second_argument_type); - CGAL_static_assertion( - (::std::is_same::value)); + static_assert(::std::is_same::value); } int i; diff --git a/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/Algebraic_curve_kernel_2.h b/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/Algebraic_curve_kernel_2.h index 002e108b0ec..e92e01e0669 100644 --- a/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/Algebraic_curve_kernel_2.h +++ b/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/Algebraic_curve_kernel_2.h @@ -481,18 +481,18 @@ public: Curve_analysis_2 _construct_defining_polynomial_from(Bound b) const { typedef CGAL::Fraction_traits FT; // We rely on the fact that the Bound is a fraction - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef typename FT::Numerator_type Numerator; typedef typename FT::Denominator_type Denominator; typedef CGAL::Coercion_traits Num_coercion; - CGAL_static_assertion((::std::is_same + static_assert(::std::is_same ::value)); + typename Num_coercion::Type>::value); typedef CGAL::Coercion_traits Denom_coercion; - CGAL_static_assertion((::std::is_same + static_assert(::std::is_same ::value)); + typename Denom_coercion::Type>::value); typename Num_coercion::Cast num_cast; typename Denom_coercion::Cast denom_cast; typename FT::Decompose decompose; @@ -2541,18 +2541,18 @@ public: Polynomial_1 operator() (const Polynomial_2& f, Bound b) const { typedef CGAL::Fraction_traits FT; // We rely on the fact that the Bound is a fraction - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef typename FT::Numerator_type Numerator; typedef typename FT::Denominator_type Denominator; typedef CGAL::Coercion_traits Num_coercion; - CGAL_static_assertion((::std::is_same + static_assert(::std::is_same ::value)); + typename Num_coercion::Type>::value); typedef CGAL::Coercion_traits Denom_coercion; - CGAL_static_assertion((::std::is_same + static_assert(::std::is_same ::value)); + typename Denom_coercion::Type>::value); typename Num_coercion::Cast num_cast; typename Denom_coercion::Cast denom_cast; typename FT::Decompose decompose; diff --git a/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/Algebraic_real_d_1.h b/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/Algebraic_real_d_1.h index 54fcec0b3f5..2b5a30867ce 100644 --- a/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/Algebraic_real_d_1.h +++ b/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/Algebraic_real_d_1.h @@ -71,7 +71,7 @@ class Algebraic_real_d_1 : public ::CGAL::Handle_with_policy< AlgebraicRealRep_d_1, HandlePolicy > { // currently Rational is the only supported Bound type. - CGAL_static_assertion( + static_assert( ( ::std::is_same ::Arithmetic_kernel::Rational>::value)); diff --git a/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/Curve_analysis_2.h b/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/Curve_analysis_2.h index b8bd5995a6f..70db25837e9 100644 --- a/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/Curve_analysis_2.h +++ b/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/Curve_analysis_2.h @@ -23,7 +23,6 @@ #include #include -#include #include #include @@ -66,14 +65,14 @@ namespace internal { template struct Is_derived_from_Handle_with_policy { - typedef boost::false_type Tag; + typedef std::false_type Tag; }; template struct Is_derived_from_Handle_with_policy { typedef typename - boost::is_base_of< CGAL::Handle_with_policy + std::is_base_of< CGAL::Handle_with_policy < typename Comparable::T, typename Comparable::Handle_policy, typename Comparable::Allocator >, @@ -90,7 +89,7 @@ template struct Compare_for_vert_line_map_ }; template - struct Compare_for_vert_line_map_ { + struct Compare_for_vert_line_map_ { bool operator() (const Comparable& a, const Comparable& b) const { return CGAL::Handle_id_less_than< Comparable >()(a,b); diff --git a/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/algebraic_curve_kernel_2_tools.h b/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/algebraic_curve_kernel_2_tools.h index 1609fdbaa6b..e9ff71e3e66 100644 --- a/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/algebraic_curve_kernel_2_tools.h +++ b/Algebraic_kernel_d/include/CGAL/Algebraic_kernel_d/algebraic_curve_kernel_2_tools.h @@ -186,7 +186,7 @@ template::value_type >::value)); @@ -224,14 +224,14 @@ template void cast_back_utcf(const Poly_coer_1& p,Polynomial_1& q) { // We can assume that both template arguments are polynomial types typedef CGAL::Fraction_traits FT; - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); typedef typename FT::Numerator_type Numerator; typedef typename FT::Denominator_type Denominator; typedef CGAL::Coercion_traits Num_coercion; - CGAL_static_assertion((::std::is_same + static_assert(::std::is_same ::value)); + typename Num_coercion::Type>::value); Numerator p_num; Denominator p_denom; typename FT::Decompose()(p,p_num,p_denom); diff --git a/Algebraic_kernel_d/test/Algebraic_kernel_d/Real_embeddable_traits_extension.cpp b/Algebraic_kernel_d/test/Algebraic_kernel_d/Real_embeddable_traits_extension.cpp index 2e06d3b6aec..d5917a016e5 100644 --- a/Algebraic_kernel_d/test/Algebraic_kernel_d/Real_embeddable_traits_extension.cpp +++ b/Algebraic_kernel_d/test/Algebraic_kernel_d/Real_embeddable_traits_extension.cpp @@ -47,8 +47,8 @@ void test_real_embeddable_extension(const NT_&){ typedef typename Floor::result_type Result_type; CGAL_USE_TYPE(Argument_type); CGAL_USE_TYPE(Result_type); - CGAL_static_assertion(( ::std::is_same::value)); - CGAL_static_assertion(( ::std::is_same::value)); + static_assert(::std::is_same::value); + static_assert(::std::is_same::value); assert(Integer(42) == floor(NT(42))); assert(Integer(-42) == floor(NT(-42))); } @@ -59,8 +59,8 @@ void test_real_embeddable_extension(const NT_&){ typedef typename Floor_log2_abs::result_type Result_type; CGAL_USE_TYPE(Argument_type); CGAL_USE_TYPE(Result_type); - CGAL_static_assertion(( ::std::is_same::value)); - CGAL_static_assertion(( ::std::is_same::value)); + static_assert(::std::is_same::value); + static_assert(::std::is_same::value); assert(long(0) == floor_log2_abs(NT(1))); assert(long(0) == floor_log2_abs(NT(-1))); @@ -86,8 +86,8 @@ void test_real_embeddable_extension(const NT_&){ typedef typename Ceil::result_type Result_type; CGAL_USE_TYPE(Argument_type); CGAL_USE_TYPE(Result_type); - CGAL_static_assertion(( ::std::is_same::value)); - CGAL_static_assertion(( ::std::is_same::value)); + static_assert(::std::is_same::value); + static_assert(::std::is_same::value); assert(Integer(42) == ceil(NT(42))); assert(Integer(-42) == ceil(NT(-42))); } @@ -98,8 +98,8 @@ void test_real_embeddable_extension(const NT_&){ typedef typename Ceil_log2_abs::result_type Result_type; CGAL_USE_TYPE(Argument_type); CGAL_USE_TYPE(Result_type); - CGAL_static_assertion(( ::std::is_same::value)); - CGAL_static_assertion(( ::std::is_same::value)); + static_assert(::std::is_same::value); + static_assert(::std::is_same::value); assert(long(0) == ceil_log2_abs(NT(1))); assert(long(0) == ceil_log2_abs(NT(-1))); diff --git a/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_algebraic_curve_kernel_2.h b/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_algebraic_curve_kernel_2.h index 01a27244d74..f3332c1a4d2 100644 --- a/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_algebraic_curve_kernel_2.h +++ b/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_algebraic_curve_kernel_2.h @@ -62,20 +62,20 @@ void test_algebraic_curve_kernel_2() { typedef AlgebraicCurveKernel_2 AK_2; - /* CGAL_static_assertion( (::std::is_same< - Algebraic_real_1, typename AK::Algebraic_real_1 >::value) ); + /* static_assert(::std::is_same< + Algebraic_real_1, typename AK::Algebraic_real_1 >::value); - CGAL_static_assertion((::std::is_same< + static_assert(::std::is_same< Isolator, - typename AK::Isolator >::value) ); + typename AK::Isolator >::value); - CGAL_static_assertion((::std::is_same< + static_assert(::std::is_same< Coefficient, - typename AK::Coefficient >::value)); + typename AK::Coefficient >::value); - CGAL_static_assertion((::std::is_same< + static_assert(::std::is_same< Polynomial_1, - typename AK::Polynomial_1 >::value));*/ + typename AK::Polynomial_1 >::value);*/ typedef typename AK_2::Polynomial_2 Poly_2; typedef typename AK_2::Curve_analysis_2 Curve_analysis_2; diff --git a/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_algebraic_kernel_1.h b/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_algebraic_kernel_1.h index 20ecd337223..abe5ebfd32d 100644 --- a/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_algebraic_kernel_1.h +++ b/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_algebraic_kernel_1.h @@ -109,8 +109,8 @@ void test_algebraic_kernel_1(const AlgebraicKernel_d_1& ak_1){ typedef typename Name::result_type RT_; \ CGAL_USE_TYPE(AT_); \ CGAL_USE_TYPE(RT_); \ - {CGAL_static_assertion(( ::std::is_same::value));} \ - {CGAL_static_assertion(( ::std::is_same::value));} \ + {static_assert(::std::is_same::value);} \ + {static_assert(::std::is_same::value);} \ } #define CGAL_CHECK_BFUNCTION(Name,AT1,AT2,RT) \ { \ @@ -120,9 +120,9 @@ void test_algebraic_kernel_1(const AlgebraicKernel_d_1& ak_1){ CGAL_USE_TYPE(AT1_); \ CGAL_USE_TYPE(AT2_); \ CGAL_USE_TYPE(RT_); \ - {CGAL_static_assertion(( ::std::is_same::value));} \ - {CGAL_static_assertion(( ::std::is_same::value));} \ - {CGAL_static_assertion(( ::std::is_same::value));} \ + {static_assert(::std::is_same::value);} \ + {static_assert(::std::is_same::value);} \ + {static_assert(::std::is_same::value);} \ } // TODO: missing check for Construct_algebraic_real_1 diff --git a/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_algebraic_kernel_2.h b/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_algebraic_kernel_2.h index ff04c8f8c9d..bebcd0118e7 100644 --- a/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_algebraic_kernel_2.h +++ b/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_algebraic_kernel_2.h @@ -93,8 +93,8 @@ void test_algebraic_kernel_2(const AlgebraicKernel_2& ak_2) { typedef typename Name::result_type RT_; \ CGAL_USE_TYPE(AT_); \ CGAL_USE_TYPE(RT_); \ - {CGAL_static_assertion(( ::std::is_same::value));} \ - {CGAL_static_assertion(( ::std::is_same::value));} \ + {static_assert(::std::is_same::value);} \ + {static_assert(::std::is_same::value);} \ } #define CGAL_CHECK_BFUNCTION(Name,AT1,AT2,RT) \ { \ @@ -104,22 +104,22 @@ void test_algebraic_kernel_2(const AlgebraicKernel_2& ak_2) { CGAL_USE_TYPE(AT1_); \ CGAL_USE_TYPE(AT2_); \ CGAL_USE_TYPE(RT_); \ - {CGAL_static_assertion(( ::std::is_same::value));} \ - {CGAL_static_assertion(( ::std::is_same::value));} \ - {CGAL_static_assertion(( ::std::is_same::value));} \ + {static_assert(::std::is_same::value);} \ + {static_assert(::std::is_same::value);} \ + {static_assert(::std::is_same::value);} \ } - CGAL_static_assertion(( ::std::is_same + static_assert(::std::is_same - ::value)); + ::value); CGAL_CHECK_UFUNCTION(Is_square_free_2,Polynomial_2,bool); CGAL_CHECK_UFUNCTION(Make_square_free_2,Polynomial_2,Polynomial_2); // TODO: missing check for Square_free_factorize_2 CGAL_CHECK_BFUNCTION(Is_coprime_2,Polynomial_2,Polynomial_2,bool); - CGAL_static_assertion(( ::std::is_same - ::value)); + static_assert(::std::is_same + ::value); CGAL_CHECK_BFUNCTION(Number_of_solutions_2,Polynomial_2,Polynomial_2, size_type); CGAL_CHECK_UFUNCTION(Compute_x_2,Algebraic_real_2,Algebraic_real_1); @@ -128,8 +128,8 @@ void test_algebraic_kernel_2(const AlgebraicKernel_2& ak_2) { CGAL_CHECK_UFUNCTION(Compute_polynomial_y_2,Algebraic_real_2,Polynomial_1); CGAL_CHECK_BFUNCTION(Isolate_x_2,Algebraic_real_2,Polynomial_1,BInterval); CGAL_CHECK_BFUNCTION(Isolate_y_2,Algebraic_real_2,Polynomial_1,BInterval); - CGAL_static_assertion(( ::std::is_same - < BArray,typename Isolate_2::result_type>::value)); + static_assert(::std::is_same + < BArray,typename Isolate_2::result_type>::value); CGAL_CHECK_BFUNCTION(Sign_at_2,Polynomial_2,Algebraic_real_2,Sign); CGAL_CHECK_BFUNCTION(Is_zero_at_2,Polynomial_2,Algebraic_real_2,bool); CGAL_CHECK_BFUNCTION(Compare_x_2,Algebraic_real_2,Algebraic_real_2,Sign); diff --git a/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_real_comparable.h b/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_real_comparable.h index a393abe3653..fa5bd929abe 100644 --- a/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_real_comparable.h +++ b/Algebraic_kernel_d/test/Algebraic_kernel_d/include/CGAL/_test_real_comparable.h @@ -39,8 +39,8 @@ namespace internal { void operator() (ToDouble to_double) { typedef typename ToDouble::argument_type Argument_type; typedef typename ToDouble::result_type Result_type; - CGAL_static_assertion((::std::is_same::value)); - CGAL_static_assertion((::std::is_same::value)); + static_assert(::std::is_same::value); + static_assert(::std::is_same::value); assert(42.0 == to_double(NT(42))); } }; @@ -59,8 +59,8 @@ namespace internal { void operator() (ToInterval to_Interval) { typedef typename ToInterval::argument_type Argument_type; typedef typename ToInterval::result_type Result_type; - CGAL_static_assertion((::std::is_same::value)); - CGAL_static_assertion((::std::is_same< typename Argument_type::Interval, Result_type>::value)); + static_assert(::std::is_same::value); + static_assert(::std::is_same< typename Argument_type::Interval, Result_type>::value); // TODO: NiX::in not available!? //assert(NiX::in(42.0,to_Interval(NT(42)))); @@ -99,7 +99,7 @@ void test_real_comparable() { typedef CGAL::Real_embeddable_traits Traits; typedef typename Traits::Is_real_embeddable Is_real_comparable; using ::CGAL::Tag_true; - CGAL_static_assertion((::std::is_same< Is_real_comparable, Tag_true>::value)); + static_assert(::std::is_same< Is_real_comparable, Tag_true>::value); typename Traits::Compare compare; typename Traits::Sign sign; typename Traits::Abs abs; @@ -168,20 +168,20 @@ void test_not_real_comparable() { typedef CGAL::Real_embeddable_traits Traits; typedef typename Traits::Is_real_embeddable Is_real_comparable; using ::CGAL::Tag_false; - CGAL_static_assertion((::std::is_same< Is_real_comparable, Tag_false>::value)); + static_assert(::std::is_same< Is_real_comparable, Tag_false>::value); } template void test_rounded_log2_abs(NT zero, ::CGAL::Null_functor, CeilLog2Abs) { typedef ::CGAL::Null_functor Nulltype; - CGAL_static_assertion((::std::is_same< CeilLog2Abs, Nulltype>::value)); + static_assert(::std::is_same< CeilLog2Abs, Nulltype>::value); } template void test_rounded_log2_abs(NT zero, FloorLog2Abs fl_log, CeilLog2Abs cl_log) { typedef ::CGAL::Null_functor Null_functor; - CGAL_static_assertion((!::std::is_same< CeilLog2Abs, Null_functor>::value)); + static_assert(!::std::is_same< CeilLog2Abs, Null_functor>::value); assert( fl_log(NT( 7)) == 2 ); assert( cl_log(NT( 7)) == 3 ); diff --git a/Alpha_shapes_2/doc/Alpha_shapes_2/CGAL/Alpha_shape_2.h b/Alpha_shapes_2/doc/Alpha_shapes_2/CGAL/Alpha_shape_2.h index 98dedd0f75b..832be2b8d29 100644 --- a/Alpha_shapes_2/doc/Alpha_shapes_2/CGAL/Alpha_shape_2.h +++ b/Alpha_shapes_2/doc/Alpha_shapes_2/CGAL/Alpha_shape_2.h @@ -80,7 +80,7 @@ use binary search. `Alpha_shape_2::number_of_solid_components()` performs a graph traversal and takes time linear in the number of faces of the underlying triangulation. `Alpha_shape_2::find_optimal_alpha()` uses binary search and takes time -\f$ O(n \log n)\f$, where \f$ n\f$ is the number of points. +\cgalBigO{n \log n}, where \f$ n\f$ is the number of points. */ template< typename Dt, typename ExactAlphaComparisonTag > diff --git a/Alpha_shapes_2/include/CGAL/Alpha_shape_2.h b/Alpha_shapes_2/include/CGAL/Alpha_shape_2.h index 3c4cb4b7d30..43be2407022 100644 --- a/Alpha_shapes_2/include/CGAL/Alpha_shape_2.h +++ b/Alpha_shapes_2/include/CGAL/Alpha_shape_2.h @@ -61,7 +61,7 @@ public: // because the periodic triangulations' point() function returns a temporary // value while the lazy predicate evaluations that are used when the Exact tag // is set to true rely on a permanent and safe access to the points. - CGAL_static_assertion( + static_assert( (std::is_same::value) || (std::is_same::value)); @@ -76,8 +76,8 @@ public: typedef Type_of_alpha FT; // check that simplices are correctly instantiated - CGAL_static_assertion( (std::is_same::value) ); - CGAL_static_assertion( (std::is_same::value) ); + static_assert(std::is_same::value); + static_assert(std::is_same::value); typedef typename Dt::Point Point; diff --git a/Alpha_shapes_2/include/CGAL/Alpha_shape_vertex_base_2.h b/Alpha_shapes_2/include/CGAL/Alpha_shape_vertex_base_2.h index e96dfaa5fcb..919fec145ec 100644 --- a/Alpha_shapes_2/include/CGAL/Alpha_shape_vertex_base_2.h +++ b/Alpha_shapes_2/include/CGAL/Alpha_shape_vertex_base_2.h @@ -19,6 +19,7 @@ #include #include #include +#include //------------------------------------------------------------------- namespace CGAL { diff --git a/Alpha_shapes_2/include/CGAL/Alpha_shapes_2/internal/Lazy_alpha_nt_2.h b/Alpha_shapes_2/include/CGAL/Alpha_shapes_2/internal/Lazy_alpha_nt_2.h index cc734b7f4b6..728cb446934 100644 --- a/Alpha_shapes_2/include/CGAL/Alpha_shapes_2/internal/Lazy_alpha_nt_2.h +++ b/Alpha_shapes_2/include/CGAL/Alpha_shapes_2/internal/Lazy_alpha_nt_2.h @@ -148,8 +148,8 @@ 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_2< - Input_traits, Kernel_approx, Kernel_exact, Weighted_tag>::value)); + static_assert(Is_traits_point_convertible_2< + Input_traits, Kernel_approx, Kernel_exact, Weighted_tag>::value); To_approx converter; return converter(wp); @@ -158,8 +158,8 @@ 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_2< - Input_traits, Kernel_approx, Kernel_exact, Weighted_tag>::value)); + static_assert(Is_traits_point_convertible_2< + Input_traits, Kernel_approx, Kernel_exact, Weighted_tag>::value); To_exact converter; return converter(wp); @@ -448,7 +448,7 @@ struct Alpha_nt_selector_2 GeomTraits, // If the base traits is already exact then we don't need to do anything, // and we can simply directly use the traits class - Boolean_tag::value && + Boolean_tag::value && ExactAlphaComparisonTag::value >, Weighted_tag> { }; diff --git a/Alpha_shapes_2/package_info/Alpha_shapes_2/dependencies b/Alpha_shapes_2/package_info/Alpha_shapes_2/dependencies index eee8e076278..6c159737638 100644 --- a/Alpha_shapes_2/package_info/Alpha_shapes_2/dependencies +++ b/Alpha_shapes_2/package_info/Alpha_shapes_2/dependencies @@ -2,7 +2,6 @@ Algebraic_foundations Alpha_shapes_2 Arithmetic_kernel Cartesian_kernel -Filtered_kernel Hash_map Homogeneous_kernel Installation diff --git a/Alpha_shapes_3/doc/Alpha_shapes_3/CGAL/Alpha_shape_3.h b/Alpha_shapes_3/doc/Alpha_shapes_3/CGAL/Alpha_shape_3.h index 70f1bec2182..7136eed539b 100644 --- a/Alpha_shapes_3/doc/Alpha_shapes_3/CGAL/Alpha_shape_3.h +++ b/Alpha_shapes_3/doc/Alpha_shapes_3/CGAL/Alpha_shape_3.h @@ -77,7 +77,7 @@ use binary search. `Alpha_shape_3::number_of_solid_components()` performs a graph traversal and takes time linear in the number of cells of the underlying triangulation. `Alpha_shape_3::find_optimal_alpha()` uses binary search and takes time -\f$ O(n \log n)\f$, where \f$ n\f$ is the number of points. +\cgalBigO{n \log n}, where \f$ n\f$ is the number of points. */ template< typename Dt, typename ExactAlphaComparisonTag > diff --git a/Alpha_shapes_3/include/CGAL/Alpha_shape_3.h b/Alpha_shapes_3/include/CGAL/Alpha_shape_3.h index be6849a5886..a4a93f82515 100644 --- a/Alpha_shapes_3/include/CGAL/Alpha_shape_3.h +++ b/Alpha_shapes_3/include/CGAL/Alpha_shape_3.h @@ -97,7 +97,7 @@ public: // because the periodic triangulations' point() function returns a temporary // value while the lazy predicate evaluations that are used when the Exact tag // is set to true rely on a permanent and safe access to the points. - CGAL_static_assertion( + static_assert( (std::is_same::value) || (std::is_same::value)); @@ -108,8 +108,8 @@ public: typedef typename Gt::FT Coord_type; //checks whether tags are correctly set in Vertex and Cell classes - CGAL_static_assertion( (std::is_same::value) ); - CGAL_static_assertion( (std::is_same::value) ); + static_assert(std::is_same::value); + static_assert(std::is_same::value); typedef typename Dt::Point Point; diff --git a/Alpha_shapes_3/include/CGAL/Alpha_shapes_3/internal/Lazy_alpha_nt_3.h b/Alpha_shapes_3/include/CGAL/Alpha_shapes_3/internal/Lazy_alpha_nt_3.h index cd853624378..d753b2457cb 100644 --- a/Alpha_shapes_3/include/CGAL/Alpha_shapes_3/internal/Lazy_alpha_nt_3.h +++ b/Alpha_shapes_3/include/CGAL/Alpha_shapes_3/internal/Lazy_alpha_nt_3.h @@ -139,8 +139,8 @@ 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_3< - Input_traits, Kernel_approx, Kernel_exact, Weighted_tag>::value)); + static_assert(Is_traits_point_convertible_3< + Input_traits, Kernel_approx, Kernel_exact, Weighted_tag>::value); To_approx converter; return converter(wp); @@ -149,8 +149,8 @@ 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_3< - Input_traits, Kernel_approx, Kernel_exact, Weighted_tag>::value)); + static_assert(Is_traits_point_convertible_3< + Input_traits, Kernel_approx, Kernel_exact, Weighted_tag>::value); To_exact converter; return converter(wp); @@ -417,7 +417,7 @@ struct Alpha_nt_selector_3 GeomTraits, // If the base traits is already exact then we don't need to do anything, // and we can simply directly use the traits class - Boolean_tag::value && + Boolean_tag::value && ExactAlphaComparisonTag::value >, Weighted_tag> { }; diff --git a/Alpha_shapes_3/include/CGAL/Fixed_alpha_shape_3.h b/Alpha_shapes_3/include/CGAL/Fixed_alpha_shape_3.h index f599e971bb0..586f82ddfe3 100644 --- a/Alpha_shapes_3/include/CGAL/Fixed_alpha_shape_3.h +++ b/Alpha_shapes_3/include/CGAL/Fixed_alpha_shape_3.h @@ -27,7 +27,6 @@ #include #include #include -#include #include #include @@ -255,7 +254,7 @@ public: std::back_inserter(cells), Emptyset_iterator())); - Facet facet=*boost::prior(facets_on_the_boundary_of_the_hole.end()); + Facet facet=*std::prev(facets_on_the_boundary_of_the_hole.end()); // Remember the points that are hidden by the conflicting cells, // as they will be deleted during the insertion. diff --git a/Alpha_wrap_3/include/CGAL/Alpha_wrap_3/internal/Alpha_wrap_3.h b/Alpha_wrap_3/include/CGAL/Alpha_wrap_3/internal/Alpha_wrap_3.h index 20982e9beaa..f12ad06804b 100644 --- a/Alpha_wrap_3/include/CGAL/Alpha_wrap_3/internal/Alpha_wrap_3.h +++ b/Alpha_wrap_3/include/CGAL/Alpha_wrap_3/internal/Alpha_wrap_3.h @@ -173,7 +173,7 @@ class Alpha_wrap_3 using Alpha_PQ = Modifiable_priority_queue, CGAL_BOOST_PAIRING_HEAP>; protected: - const Oracle& m_oracle; + const Oracle m_oracle; SC_Iso_cuboid_3 m_bbox; FT m_alpha, m_sq_alpha; @@ -193,7 +193,7 @@ public: { // Due to the Steiner point computation being a dichotomy, the algorithm is inherently inexact // and passing exact kernels is explicitly disabled to ensure no misunderstanding. - CGAL_static_assertion((std::is_floating_point::value)); + static_assert(std::is_floating_point::value); } public: @@ -1343,6 +1343,7 @@ private: return true; } +public: // Not the best complexity, but it's very cheap compared to the rest of the algorithm. void make_manifold() { diff --git a/Alpha_wrap_3/include/CGAL/Alpha_wrap_3/internal/Triangle_mesh_oracle.h b/Alpha_wrap_3/include/CGAL/Alpha_wrap_3/internal/Triangle_mesh_oracle.h index 6d0f65142f6..c87f82ac75f 100644 --- a/Alpha_wrap_3/include/CGAL/Alpha_wrap_3/internal/Triangle_mesh_oracle.h +++ b/Alpha_wrap_3/include/CGAL/Alpha_wrap_3/internal/Triangle_mesh_oracle.h @@ -146,7 +146,7 @@ public: VPM vpm = choose_parameter(get_parameter(np, internal_np::vertex_point), get_const_property_map(vertex_point, tmesh)); - CGAL_static_assertion((std::is_same::value_type, Point_3>::value)); + static_assert(std::is_same::value_type, Point_3>::value); Splitter_base::reserve(num_faces(tmesh)); diff --git a/Alpha_wrap_3/include/CGAL/Alpha_wrap_3/internal/Triangle_soup_oracle.h b/Alpha_wrap_3/include/CGAL/Alpha_wrap_3/internal/Triangle_soup_oracle.h index 57f936306da..0a8f589fc2d 100644 --- a/Alpha_wrap_3/include/CGAL/Alpha_wrap_3/internal/Triangle_soup_oracle.h +++ b/Alpha_wrap_3/include/CGAL/Alpha_wrap_3/internal/Triangle_soup_oracle.h @@ -143,7 +143,7 @@ public: #endif PPM pm = choose_parameter(get_parameter(np, internal_np::point_map)); - CGAL_static_assertion((std::is_same::value_type, Point_3>::value)); + static_assert(std::is_same::value_type, Point_3>::value); Splitter_base::reserve(faces.size()); diff --git a/Arithmetic_kernel/test/Arithmetic_kernel/CMakeLists.txt b/Arithmetic_kernel/test/Arithmetic_kernel/CMakeLists.txt index 08d054ea54c..d23762f811e 100644 --- a/Arithmetic_kernel/test/Arithmetic_kernel/CMakeLists.txt +++ b/Arithmetic_kernel/test/Arithmetic_kernel/CMakeLists.txt @@ -39,6 +39,7 @@ if(GMP_FOUND) create_single_source_cgal_program("Arithmetic_kernel.cpp") create_single_source_cgal_program("LEDA_arithmetic_kernel.cpp") create_single_source_cgal_program("CORE_arithmetic_kernel.cpp") + create_single_source_cgal_program("GMPXX_arithmetic_kernel.cpp") create_single_source_cgal_program("Get_arithmetic_kernel.cpp") else() diff --git a/Arithmetic_kernel/test/Arithmetic_kernel/Get_arithmetic_kernel.cpp b/Arithmetic_kernel/test/Arithmetic_kernel/Get_arithmetic_kernel.cpp index f8b373c9764..7c48e66a2c1 100644 --- a/Arithmetic_kernel/test/Arithmetic_kernel/Get_arithmetic_kernel.cpp +++ b/Arithmetic_kernel/test/Arithmetic_kernel/Get_arithmetic_kernel.cpp @@ -18,17 +18,17 @@ int main() { { typedef CGAL::Get_arithmetic_kernel::Arithmetic_kernel AK_; CGAL_USE_TYPE(AK_); - CGAL_static_assertion((std::is_same::value)); + static_assert(std::is_same::value); } { typedef CGAL::Get_arithmetic_kernel::Arithmetic_kernel AK_; CGAL_USE_TYPE(AK_); - CGAL_static_assertion((std::is_same::value)); + static_assert(std::is_same::value); } { typedef CGAL::Get_arithmetic_kernel::Arithmetic_kernel AK_; CGAL_USE_TYPE(AK_); - CGAL_static_assertion((std::is_same::value)); + static_assert(std::is_same::value); } return 0; } diff --git a/Arrangement_on_surface_2/demo/Arrangement_on_surface_2/AlgebraicCurveParser.cpp b/Arrangement_on_surface_2/demo/Arrangement_on_surface_2/AlgebraicCurveParser.cpp index 009eede6a79..d54d5242074 100644 --- a/Arrangement_on_surface_2/demo/Arrangement_on_surface_2/AlgebraicCurveParser.cpp +++ b/Arrangement_on_surface_2/demo/Arrangement_on_surface_2/AlgebraicCurveParser.cpp @@ -12,7 +12,7 @@ // This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE // WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. // -// SPDX-License-Identifier: GPL-3.0+ +// SPDX-License-Identifier: GPL-3.0-or-later // // Author(s): Saurabh Singh // Ahmed Essam diff --git a/Arrangement_on_surface_2/demo/Arrangement_on_surface_2/AlgebraicCurveParser.h b/Arrangement_on_surface_2/demo/Arrangement_on_surface_2/AlgebraicCurveParser.h index e838f2e3c0d..5e8ac4b0fd2 100644 --- a/Arrangement_on_surface_2/demo/Arrangement_on_surface_2/AlgebraicCurveParser.h +++ b/Arrangement_on_surface_2/demo/Arrangement_on_surface_2/AlgebraicCurveParser.h @@ -12,7 +12,7 @@ // This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE // WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. // -// SPDX-License-Identifier: GPL-3.0+ +// SPDX-License-Identifier: GPL-3.0-or-later // // Author(s): Saurabh Singh // Ahmed Essam diff --git a/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/Arrangement_on_surface_2.txt b/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/Arrangement_on_surface_2.txt index 431083db107..62571bfdee9 100644 --- a/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/Arrangement_on_surface_2.txt +++ b/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/Arrangement_on_surface_2.txt @@ -1223,10 +1223,10 @@ halfedge \f$e_{\mathrm{pred}}\f$ directed toward \f$v\f$, such that \f$c\f$ is located between the curves associated with \f$e_{\mathrm{pred}}\f$ and the next halfedge in the clockwise order in the circular list of halfedges around \f$v\f$; see -\cgalFigureRef{aos_fig-insert}. This search may take \f$O(d)\f$ time, +\cgalFigureRef{aos_fig-insert}. This search may take \cgalBigO{d} time, where \f$d\f$ is the degree of the vertex \f$v\f$. \cgalFootnote{We can store the handles to the halfedges incident to \f$v\f$ in an efficient -search structure to obtain \f$O(\log d)\f$ access time. However, as +search structure to obtain \cgalBigO{\log d} access time. However, as \f$d\f$ is usually very small, this may lead to a waste of storage space without a meaningful improvement in running time in practice.} However, if the halfedge \f$e_{\mathrm{pred}}\f$ is known in advance, @@ -1488,9 +1488,9 @@ keep up-to-date as this arrangement changes. As mentioned above, the triangulation strategy is provided only for educational purposes, and thus we do not elaborate on this strategy. The data structure needed by the landmark and the trapezoidal map RIC -strategies can be constructed in \f$O(N \log N)\f$ time, where \f$N\f$ +strategies can be constructed in \cgalBigO{N \log N} time, where \f$N\f$ is the overall number of edges in the arrangement, but the constant -hidden in the \f$O()\f$ notation for the trapezoidal map RIC strategy +hidden in the \cgalBigO{ } notation for the trapezoidal map RIC strategy is much larger. Thus, construction needed by the landmark algorithm is in practice significantly faster than the construction needed by the trapezoidal map RIC strategy. In addition, although both resulting @@ -1647,7 +1647,7 @@ Section \ref arr_ssecpl. The output pairs are sorted in increasing \f$xy\f$-lexicographical order of the query point. The batched point-location operation is carried out by sweeping the -arrangement. Thus, it takes \f$O((m+N)\log{(m+N)})\f$ time, where +arrangement. Thus, it takes \cgalBigO{(m+N)\log{(m+N)}} time, where \f$N\f$ is the number of edges in the arrangement. Issuing separate queries exploiting a point-location strategy with logarithmic query time per query, such as the trapezoidal map RIC strategy (see Section @@ -2037,11 +2037,11 @@ so it must be construct from scratch. In the first case, we sweep over the input curves, compute their intersection points, and construct the \dcel that represents their -arrangement. This process is performed in \f$O\left((n + k)\log -n\right)\f$ time, where \f$k\f$ is the total number of intersection +arrangement. This process is performed in \cgalBigO{left((n + k)\log +n\right} time, where \f$k\f$ is the total number of intersection points. The running time is asymptotically better than the time needed for incremental insertion if the arrangement is relatively sparse -(when \f$k\f$ is \f$O(\frac{n^2}{\log n}\f$)), but it is recommended +(when \f$k\f$ is \cgalBigO{\frac{n^2}{\log n}}), but it is recommended that this aggregate construction process be used even for dense arrangements, since the plane-sweep algorithm performs fewer geometric operations compared to the incremental insertion algorithms, and hence @@ -4346,7 +4346,7 @@ a point with respect to an \f$x\f$-monotone polyline, we use binary search to locate the relevant segment that contains the point in its \f$x\f$-range. Then, we compute the position of the point with respect to this segment. Thus, operations on \f$x\f$-monotone polylines of -size \f$m\f$ typically take \f$O(\log m)\f$ time. +size \f$m\f$ typically take \cgalBigO{\log m} time. You are free to choose the underlying segment traits class. Your decision could be based, for example, on the number of expected diff --git a/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/CGAL/Arr_trapezoid_ric_point_location.h b/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/CGAL/Arr_trapezoid_ric_point_location.h index 0027ec53409..e662503bee4 100644 --- a/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/CGAL/Arr_trapezoid_ric_point_location.h +++ b/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/CGAL/Arr_trapezoid_ric_point_location.h @@ -12,9 +12,9 @@ Seidel \cgalCite{s-sfira-91} (see also [\cgalCite{bkos-cgaa-00} Chapter 6). It subdivides each arrangement face to pseudo-trapezoidal cells, each of constant complexity, and constructs and maintains a linear-size search structure on top of these cells, such that each query can be answered -in \f$ O(\log n)\f$ time, where \f$ n\f$ is the complexity of the arrangement. +in \cgalBigO{\log n} time, where \f$ n\f$ is the complexity of the arrangement. -Constructing the search structures takes \f$ O(n \log n)\f$ expected time +Constructing the search structures takes \cgalBigO{n \log n} expected time and may require a small number of rebuilds \cgalCite{hkh-iiplgtds-12}. Therefore attaching a trapezoidal point-location object to an existing arrangement may incur some overhead in running times. In addition, the point-location diff --git a/Arrangement_on_surface_2/include/CGAL/Arr_bounded_planar_topology_traits_2.h b/Arrangement_on_surface_2/include/CGAL/Arr_bounded_planar_topology_traits_2.h index e1582795054..8686132cc41 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arr_bounded_planar_topology_traits_2.h +++ b/Arrangement_on_surface_2/include/CGAL/Arr_bounded_planar_topology_traits_2.h @@ -90,10 +90,10 @@ public: typedef typename Gt_adaptor_2::Top_side_category Top_side_category; typedef typename Gt_adaptor_2::Right_side_category Right_side_category; - CGAL_static_assertion((std::is_same< Left_side_category, Arr_oblivious_side_tag >::value)); - CGAL_static_assertion((std::is_same< Bottom_side_category, Arr_oblivious_side_tag >::value)); - CGAL_static_assertion((std::is_same< Top_side_category, Arr_oblivious_side_tag >::value)); - CGAL_static_assertion((std::is_same< Right_side_category, Arr_oblivious_side_tag >::value)); + static_assert(std::is_same< Left_side_category, Arr_oblivious_side_tag >::value); + static_assert(std::is_same< Bottom_side_category, Arr_oblivious_side_tag >::value); + static_assert(std::is_same< Top_side_category, Arr_oblivious_side_tag >::value); + static_assert(std::is_same< Right_side_category, Arr_oblivious_side_tag >::value); //@} /*! \struct diff --git a/Arrangement_on_surface_2/include/CGAL/Arr_circular_line_arc_traits_2.h b/Arrangement_on_surface_2/include/CGAL/Arr_circular_line_arc_traits_2.h index e913bc9f7db..4d5c07d46ea 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arr_circular_line_arc_traits_2.h +++ b/Arrangement_on_surface_2/include/CGAL/Arr_circular_line_arc_traits_2.h @@ -352,7 +352,7 @@ namespace CGAL { //typedef const result_type& qualified_result_type; template < typename T > - //typename boost::remove_reference::type + //std::remove_reference_t Circular_arc_point_2 operator()(const T &a) const { @@ -370,7 +370,7 @@ namespace CGAL { typedef Point_2 result_type; //typedef const result_type& qualified_result_type; - //typename boost::remove_reference::type + //std::remove_reference_t result_type operator() (const boost::variant< Arc1, Arc2 > & cv) const { @@ -397,7 +397,7 @@ namespace CGAL { //typedef const result_type& qualified_result_type; template < typename T > - //typename boost::remove_reference::type + //std::remove_reference_t Circular_arc_point_2 operator()(const T &a) const { @@ -420,7 +420,7 @@ namespace CGAL { typedef Point_2 result_type; //typedef const result_type& qualified_result_type; - //typename boost::remove_reference::type + //std::remove_reference result_type operator() (const boost::variant< Arc1, Arc2 > & cv) const { diff --git a/Arrangement_on_surface_2/include/CGAL/Arr_conic_traits_2.h b/Arrangement_on_surface_2/include/CGAL/Arr_conic_traits_2.h index 638e5f630b2..f7b77c63a43 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arr_conic_traits_2.h +++ b/Arrangement_on_surface_2/include/CGAL/Arr_conic_traits_2.h @@ -79,7 +79,7 @@ public: typedef Tag_true Has_left_category; typedef Tag_true Has_merge_category; typedef Tag_false Has_do_intersect_category; - //typedef boost::true_type Has_line_segment_constructor; + //typedef std::true_type Has_line_segment_constructor; typedef Arr_oblivious_side_tag Left_side_category; typedef Arr_oblivious_side_tag Bottom_side_category; diff --git a/Arrangement_on_surface_2/include/CGAL/Arr_dcel_base.h b/Arrangement_on_surface_2/include/CGAL/Arr_dcel_base.h index 39a618a754d..af2ea182fa7 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arr_dcel_base.h +++ b/Arrangement_on_surface_2/include/CGAL/Arr_dcel_base.h @@ -38,7 +38,7 @@ namespace CGAL { inline void* _clean_pointer(const void* p) { - CGAL_static_assertion(sizeof(void*) == sizeof(size_t)); + static_assert(sizeof(void*) == sizeof(size_t)); const size_t mask = ~1; const size_t val = (reinterpret_cast(p) & mask); diff --git a/Arrangement_on_surface_2/include/CGAL/Arr_geodesic_arc_on_sphere_traits_2.h b/Arrangement_on_surface_2/include/CGAL/Arr_geodesic_arc_on_sphere_traits_2.h index c87b4a357e7..7a0a2eaa3af 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arr_geodesic_arc_on_sphere_traits_2.h +++ b/Arrangement_on_surface_2/include/CGAL/Arr_geodesic_arc_on_sphere_traits_2.h @@ -66,7 +66,7 @@ public: typedef Arr_contracted_side_tag Top_side_category; typedef Arr_identified_side_tag Right_side_category; - typedef boost::integral_constant Zero_atan_y; + typedef std::integral_constant Zero_atan_y; // Traits objects typedef Arr_extended_direction_3 Point_2; @@ -358,7 +358,7 @@ public: */ void intersection_with_identification(const X_monotone_curve_2& xcv, Direction_3& dp, - boost::true_type) const + std::true_type) const { const Direction_3& normal = xcv.normal(); dp = (CGAL::sign(normal.dz()) == POSITIVE) ? @@ -371,7 +371,7 @@ public: */ void intersection_with_identification(const X_monotone_curve_2& xcv, Direction_3& dp, - boost::false_type) const + std::false_type) const { const Direction_3& normal = xcv.normal(); FT z((atan_x * normal.dx() + atan_y * normal.dy()) / @@ -383,7 +383,7 @@ public: * \param[in] cv the curve */ bool overlap_with_identification(const X_monotone_curve_2& xcv, - boost::true_type) const + std::true_type) const { const Direction_3& normal = xcv.normal(); return ((x_sign(normal) == ZERO) && @@ -395,7 +395,7 @@ public: * \param[in] cv the curve */ bool overlap_with_identification(const X_monotone_curve_2& xcv, - boost::false_type) const + std::false_type) const { const Direction_3& normal = xcv.normal(); const Direction_3& iden_normal = identification_normal(); @@ -441,7 +441,7 @@ public: Point_2 p; Direction_3& d(p); d = Direction_3(x, y, z); - init(p, boost::integral_constant()); + init(p, std::integral_constant()); return p; } @@ -454,14 +454,14 @@ public: Point_2 p; Direction_3& d(p); d = Direction_3(other); - init(p, boost::integral_constant()); + init(p, std::integral_constant()); return p; } /*! Initialize a point on the sphere, * \param[in] p the point to initialize. */ - void init(Point_2& p, boost::true_type) const + void init(Point_2& p, std::true_type) const { const Direction_3& dir = p; if (y_sign(dir) != ZERO) { @@ -480,7 +480,7 @@ public: /*! Initialize a point on the sphere, * \param[in] p the point to initialize. */ - void init(Point_2& p, boost::false_type) const + void init(Point_2& p, std::false_type) const { const Direction_3& dir = p; if ((x_sign(dir) == ZERO) && (y_sign(dir) == ZERO)) { diff --git a/Arrangement_on_surface_2/include/CGAL/Arr_overlay_2.h b/Arrangement_on_surface_2/include/CGAL/Arr_overlay_2.h index 83358c14b12..19a95a662f6 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arr_overlay_2.h +++ b/Arrangement_on_surface_2/include/CGAL/Arr_overlay_2.h @@ -172,14 +172,14 @@ overlay(const Arrangement_on_surface_2& arr1 typedef typename Agt2::Point_2 A_point; typedef typename Bgt2::Point_2 B_point; typedef typename Rgt2::Point_2 Res_point; - CGAL_static_assertion((boost::is_convertible::value)); - CGAL_static_assertion((boost::is_convertible::value)); + static_assert(std::is_convertible::value); + static_assert(std::is_convertible::value); typedef typename Agt2::X_monotone_curve_2 A_xcv; typedef typename Bgt2::X_monotone_curve_2 B_xcv; typedef typename Rgt2::X_monotone_curve_2 Res_xcv; - CGAL_static_assertion((boost::is_convertible::value)); - CGAL_static_assertion((boost::is_convertible::value)); + static_assert(std::is_convertible::value); + static_assert(std::is_convertible::value); typedef Arr_traits_basic_adaptor_2 Gt_adaptor_2; typedef Arr_overlay_traits_2 diff --git a/Arrangement_on_surface_2/include/CGAL/Arr_polycurve_basic_traits_2.h b/Arrangement_on_surface_2/include/CGAL/Arr_polycurve_basic_traits_2.h index 84c9cee01d9..c216a07bc9c 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arr_polycurve_basic_traits_2.h +++ b/Arrangement_on_surface_2/include/CGAL/Arr_polycurve_basic_traits_2.h @@ -2419,7 +2419,7 @@ protected: /*! Obtain the index of the subcurve in the polycurve that contains the * point q in its x-range. The function performs a binary search, so if the * point q is in the x-range of the polycurve with n subcurves, the subcurve - * containing it can be located in O(log n) operations. + * containing it can be located in \cgalBigO{log n} operations. * \param cv The polycurve curve. * \param q The point. * \return An index i such that q is in the x-range of cv[i]. diff --git a/Arrangement_on_surface_2/include/CGAL/Arr_rat_arc/Base_rational_arc_ds_1.h b/Arrangement_on_surface_2/include/CGAL/Arr_rat_arc/Base_rational_arc_ds_1.h index 7ebec8a5eb6..f0ff24f1291 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arr_rat_arc/Base_rational_arc_ds_1.h +++ b/Arrangement_on_surface_2/include/CGAL/Arr_rat_arc/Base_rational_arc_ds_1.h @@ -62,9 +62,9 @@ public: typedef std::vector > Root_multiplicity_vector; - CGAL_static_assertion((std::is_same::value)); - CGAL_static_assertion((std::is_same::value)); + static_assert(std::is_same::value); + static_assert(std::is_same::value); public: diff --git a/Arrangement_on_surface_2/include/CGAL/Arr_rat_arc/Rational_arc_d_1.h b/Arrangement_on_surface_2/include/CGAL/Arr_rat_arc/Rational_arc_d_1.h index ef568ab6cad..8b076506227 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arr_rat_arc/Rational_arc_d_1.h +++ b/Arrangement_on_surface_2/include/CGAL/Arr_rat_arc/Rational_arc_d_1.h @@ -100,9 +100,9 @@ public: typedef Algebraic_point_2 Point_2; - CGAL_static_assertion((std::is_same::value)); - CGAL_static_assertion((std::is_same::value)); + static_assert(std::is_same::value); + static_assert(std::is_same::value); public: const Rational_function& get_rational_function(const Polynomial_1& numerator, diff --git a/Arrangement_on_surface_2/include/CGAL/Arr_spherical_topology_traits_2.h b/Arrangement_on_surface_2/include/CGAL/Arr_spherical_topology_traits_2.h index 9b4ea137450..67202ce862f 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arr_spherical_topology_traits_2.h +++ b/Arrangement_on_surface_2/include/CGAL/Arr_spherical_topology_traits_2.h @@ -91,14 +91,14 @@ public: typedef typename Gt_adaptor_2::Top_side_category Top_side_category; typedef typename Gt_adaptor_2::Right_side_category Right_side_category; - CGAL_static_assertion((std::is_same< Left_side_category, Arr_oblivious_side_tag >::value || - std::is_same< Left_side_category, Arr_identified_side_tag >::value)); - CGAL_static_assertion((std::is_same< Bottom_side_category, Arr_oblivious_side_tag >::value || - std::is_same< Bottom_side_category, Arr_contracted_side_tag >::value)); - CGAL_static_assertion((std::is_same< Top_side_category, Arr_oblivious_side_tag >::value || - std::is_same< Top_side_category, Arr_contracted_side_tag >::value)); - CGAL_static_assertion((std::is_same< Right_side_category, Arr_oblivious_side_tag >::value || - std::is_same< Right_side_category, Arr_identified_side_tag >::value)); + static_assert(std::is_same< Left_side_category, Arr_oblivious_side_tag >::value || + std::is_same< Left_side_category, Arr_identified_side_tag >::value); + static_assert(std::is_same< Bottom_side_category, Arr_oblivious_side_tag >::value || + std::is_same< Bottom_side_category, Arr_contracted_side_tag >::value); + static_assert(std::is_same< Top_side_category, Arr_oblivious_side_tag >::value || + std::is_same< Top_side_category, Arr_contracted_side_tag >::value); + static_assert(std::is_same< Right_side_category, Arr_oblivious_side_tag >::value || + std::is_same< Right_side_category, Arr_identified_side_tag >::value); //@} /*! \struct diff --git a/Arrangement_on_surface_2/include/CGAL/Arr_unb_planar_topology_traits_2.h b/Arrangement_on_surface_2/include/CGAL/Arr_unb_planar_topology_traits_2.h index 355dd76641e..09cc7c94710 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arr_unb_planar_topology_traits_2.h +++ b/Arrangement_on_surface_2/include/CGAL/Arr_unb_planar_topology_traits_2.h @@ -87,14 +87,14 @@ public: typedef typename Gt_adaptor_2::Top_side_category Top_side_category; typedef typename Gt_adaptor_2::Right_side_category Right_side_category; - CGAL_static_assertion((std::is_same< Left_side_category, Arr_oblivious_side_tag >::value || - std::is_same< Left_side_category, Arr_open_side_tag >::value)); - CGAL_static_assertion((std::is_same< Bottom_side_category, Arr_oblivious_side_tag >::value || - std::is_same< Bottom_side_category, Arr_open_side_tag >::value)); - CGAL_static_assertion((std::is_same< Top_side_category, Arr_oblivious_side_tag>::value || - std::is_same< Top_side_category, Arr_open_side_tag >::value)); - CGAL_static_assertion((std::is_same< Right_side_category, Arr_oblivious_side_tag >::value || - std::is_same< Right_side_category, Arr_open_side_tag >::value)); + static_assert(std::is_same< Left_side_category, Arr_oblivious_side_tag >::value || + std::is_same< Left_side_category, Arr_open_side_tag >::value); + static_assert(std::is_same< Bottom_side_category, Arr_oblivious_side_tag >::value || + std::is_same< Bottom_side_category, Arr_open_side_tag >::value); + static_assert(std::is_same< Top_side_category, Arr_oblivious_side_tag>::value || + std::is_same< Top_side_category, Arr_open_side_tag >::value); + static_assert(std::is_same< Right_side_category, Arr_oblivious_side_tag >::value || + std::is_same< Right_side_category, Arr_open_side_tag >::value); //@} /*! \struct diff --git a/Arrangement_on_surface_2/include/CGAL/Arrangement_2/Arrangement_on_surface_2_global.h b/Arrangement_on_surface_2/include/CGAL/Arrangement_2/Arrangement_on_surface_2_global.h index c39c34099a5..d54f4c2cb0e 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arrangement_2/Arrangement_on_surface_2_global.h +++ b/Arrangement_on_surface_2/include/CGAL/Arrangement_2/Arrangement_on_surface_2_global.h @@ -61,7 +61,7 @@ namespace Ss2 = Surface_sweep_2; // The last parameter is used to resolve ambiguity between this function and // do_intersect of X_monotone_curve_2 in case that X_monotone_curve_2 and // Curve_2 are the same class. -// The last parameter should be boost::false_type but we used a +// The last parameter should be std::false_type but we used a // workaround since it didn't compile in FC3_g++-3.4.4 with the error of: // // error: no matching function for call to `do_intersect(Arrangement_2<>&, @@ -132,7 +132,7 @@ void insert(Arrangement_on_surface_2& arr, // // The last parameter is used to resolve ambiguity between this function and // do_intersect of Curve_2 in case that X_monotone_curve_2 and Curve_2 are the -// same class. The last parameter should be boost::true_type but we used a +// same class. The last parameter should be std::true_type but we used a // workaround since it didn't compile in FC3_g++-3.4.4 with the error of: // // error: no matching function for call to `do_intersect(Arrangement_2<>&, @@ -406,7 +406,7 @@ void insert_non_empty(Arrangement_on_surface_2&, @@ -460,7 +460,7 @@ void insert(Arrangement_on_surface_2& arr, // // The last parameter is used to resolve ambiguity between this function and // insert of Curve_2 in case that X_monotone_curve_2 and Curve_2 are the -// same class. The last parameter should be boost::true_type but we used a +// same class. The last parameter should be std::true_type but we used a // workaround since it didn't compile in FC3_g++-3.4.4 with the error of: // // error: no matching function for call to `do_intersect(Arrangement_2<>&, @@ -1522,7 +1522,7 @@ zone(Arrangement_on_surface_2& arr, // Checks whether the given x-monotone curve intersects the existing arrangement. // The last parameter is used to resolve ambiguity between this function and // do_intersect of Curve_2 in case that X_monotone_curve_2 and Curve_2 are the -// same class. The last parameter should be boost::true_type but we used a +// same class. The last parameter should be std::true_type but we used a // workaround since it didn't compile in FC3_g++-3.4.4 with the error of: // // error: no matching function for call to `do_intersect(Arrangement_on_surface_2<>&, @@ -1559,7 +1559,7 @@ do_intersect(Arrangement_on_surface_2& arr, // The last parameter is used to resolve ambiguity between this function and // do_intersect of X_monotone_curve_2 in case that X_monotone_curve_2 and // Curve_2 are the same class. -// The last parameter should be boost::false_type but we used a +// The last parameter should be std::false_type but we used a // workaround since it didn't compile in FC3_g++-3.4.4 with the error of: // // error: no matching function for call to diff --git a/Arrangement_on_surface_2/include/CGAL/Arrangement_2/arrangement_type_traits.h b/Arrangement_on_surface_2/include/CGAL/Arrangement_2/arrangement_type_traits.h index a97588ecde2..93788c728d0 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arrangement_2/arrangement_type_traits.h +++ b/Arrangement_on_surface_2/include/CGAL/Arrangement_2/arrangement_type_traits.h @@ -24,7 +24,7 @@ #include -#include +#include namespace CGAL { @@ -62,7 +62,7 @@ namespace CGAL // In the meanwhile we use a default implementation. template -class is_arrangement_2 : public boost::false_type +class is_arrangement_2 : public std::false_type {}; //-------------------------------- Arrangement_2 @@ -74,7 +74,7 @@ class Arrangement_2; template class is_arrangement_2< Arrangement_2 -> : public boost::false_type +> : public std::false_type {}; @@ -87,7 +87,7 @@ class Arrangement_on_surface_2; template class is_arrangement_2< Arrangement_on_surface_2 -> : public boost::true_type +> : public std::true_type {}; } // namespace CGAL diff --git a/Arrangement_on_surface_2/include/CGAL/Arrangement_on_surface_2.h b/Arrangement_on_surface_2/include/CGAL/Arrangement_on_surface_2.h index 438f46ced1c..ae87c8ddb28 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arrangement_on_surface_2.h +++ b/Arrangement_on_surface_2/include/CGAL/Arrangement_on_surface_2.h @@ -77,10 +77,10 @@ public: typedef typename Traits_adaptor_2::Top_side_category Top_side_category; typedef typename Traits_adaptor_2::Right_side_category Right_side_category; - CGAL_static_assertion((Arr_sane_identified_tagging::value)); + Right_side_category>::value); public: typedef Arrangement_on_surface_2 diff --git a/Arrangement_on_surface_2/include/CGAL/Arrangement_zone_2.h b/Arrangement_on_surface_2/include/CGAL/Arrangement_zone_2.h index 36f83a0e6a1..81f1c8bad04 100644 --- a/Arrangement_on_surface_2/include/CGAL/Arrangement_zone_2.h +++ b/Arrangement_on_surface_2/include/CGAL/Arrangement_zone_2.h @@ -67,10 +67,10 @@ protected: typedef typename Traits_adaptor_2::Top_side_category Top_side_category; typedef typename Traits_adaptor_2::Right_side_category Right_side_category; - CGAL_static_assertion((Arr_sane_identified_tagging::value)); + Right_side_category>::value); public: typedef ZoneVisitor_ Visitor; diff --git a/Arrangement_on_surface_2/include/CGAL/Curved_kernel_via_analysis_2/Curve_renderer_facade.h b/Arrangement_on_surface_2/include/CGAL/Curved_kernel_via_analysis_2/Curve_renderer_facade.h index c1ece0d0d57..5e95ec2d731 100644 --- a/Arrangement_on_surface_2/include/CGAL/Curved_kernel_via_analysis_2/Curve_renderer_facade.h +++ b/Arrangement_on_surface_2/include/CGAL/Curved_kernel_via_analysis_2/Curve_renderer_facade.h @@ -62,7 +62,6 @@ #include #include -#include #include diff --git a/Arrangement_on_surface_2/test/Arrangement_on_surface_2/test_tags.cpp b/Arrangement_on_surface_2/test/Arrangement_on_surface_2/test_tags.cpp index 84896d26a68..81eae420496 100644 --- a/Arrangement_on_surface_2/test/Arrangement_on_surface_2/test_tags.cpp +++ b/Arrangement_on_surface_2/test/Arrangement_on_surface_2/test_tags.cpp @@ -272,38 +272,38 @@ int main () assert(ident12() == false); - CGAL_static_assertion( + static_assert( (std::is_same< CGAL::internal::Arr_complete_left_side_category< Traits5 >::Category, CGAL::Arr_oblivious_side_tag >::value) ); - CGAL_static_assertion( + static_assert( (std::is_same< CGAL::internal::Arr_complete_left_side_category< Traits1 >::Category, CGAL::Arr_open_side_tag >::value) ); - CGAL_static_assertion( + static_assert( (std::is_same::Category, CGAL::Arr_oblivious_side_tag >::value) ); - CGAL_static_assertion( + static_assert( (std::is_same::Category, CGAL::Arr_open_side_tag >::value) ); - CGAL_static_assertion( + static_assert( (std::is_same< CGAL::internal::Arr_complete_top_side_category< Traits5 >::Category, CGAL::Arr_oblivious_side_tag >::value) ); - CGAL_static_assertion( + static_assert( (std::is_same< CGAL::internal::Arr_complete_top_side_category< Traits1 >::Category, CGAL::Arr_open_side_tag >::value) ); - CGAL_static_assertion( + static_assert( (std::is_same< CGAL::internal::Arr_complete_right_side_category< Traits5 >::Category, CGAL::Arr_oblivious_side_tag >::value) ); - CGAL_static_assertion( + static_assert( (std::is_same< CGAL::internal::Arr_complete_right_side_category< Traits1 >::Category, CGAL::Arr_open_side_tag >::value) ); diff --git a/BGL/examples/BGL_LCC/CMakeLists.txt b/BGL/examples/BGL_LCC/CMakeLists.txt index f9230373e23..84a67c0f960 100644 --- a/BGL/examples/BGL_LCC/CMakeLists.txt +++ b/BGL/examples/BGL_LCC/CMakeLists.txt @@ -9,7 +9,7 @@ find_package(CGAL REQUIRED) # create a target per cppfile file( - GLOB_RECURSE cppfiles + GLOB cppfiles RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.cpp) foreach(cppfile ${cppfiles}) diff --git a/BGL/include/CGAL/boost/graph/Dual.h b/BGL/include/CGAL/boost/graph/Dual.h index 78cc2b6c6f7..7d7481b1625 100644 --- a/BGL/include/CGAL/boost/graph/Dual.h +++ b/BGL/include/CGAL/boost/graph/Dual.h @@ -458,7 +458,7 @@ out_degree(typename boost::graph_traits >::vertex_descriptor v, const Dual

& dual) { const typename Dual

::Primal& primal = dual.primal(); - return boost::distance(halfedges_around_face(halfedge(v,primal),primal)); + return halfedges_around_face(halfedge(v,primal),primal).size(); } template diff --git a/BGL/include/CGAL/boost/graph/Face_filtered_graph.h b/BGL/include/CGAL/boost/graph/Face_filtered_graph.h index e1e9f6f0a6f..3a0a851b682 100644 --- a/BGL/include/CGAL/boost/graph/Face_filtered_graph.h +++ b/BGL/include/CGAL/boost/graph/Face_filtered_graph.h @@ -42,7 +42,7 @@ namespace CGAL { * boost::filtered_graph, * this class only requires a way to access the selected faces and will automatically select the * edges/halfedges and vertices present in the adapted graph. A vertex is selected if it is incident to at least one - * selected face. A edge is selected if it is incident to at least a selected face. A halfedge is selected if its edge + * selected face. An edge is selected if it is incident to at least a selected face. A halfedge is selected if its edge * is selected. * * Since this class is a model of the `FaceGraph` concept, there is a restriction on the set of selected faces: @@ -486,8 +486,8 @@ struct Face_filtered_graph selected_halfedges.reset(); typedef typename boost::property_traits::value_type Patch_index; - std::unordered_set pids(boost::begin(selected_face_patch_indices), - boost::end(selected_face_patch_indices)); + std::unordered_set pids(std::begin(selected_face_patch_indices), + std::end(selected_face_patch_indices)); for(face_descriptor fd : faces(_graph) ) { diff --git a/BGL/include/CGAL/boost/graph/IO/Generic_facegraph_builder.h b/BGL/include/CGAL/boost/graph/IO/Generic_facegraph_builder.h index 331f8a0f44b..1dd6235a28c 100644 --- a/BGL/include/CGAL/boost/graph/IO/Generic_facegraph_builder.h +++ b/BGL/include/CGAL/boost/graph/IO/Generic_facegraph_builder.h @@ -49,10 +49,10 @@ public: typedef typename CGAL::GetVertexPointMap::type VPM; // usually will be true, but might not be the case if using custom type points -// CGAL_static_assertion((std::is_same::value_type>::value)); -// CGAL_static_assertion((std::is_same::type>::value)); +// static_assert(std::is_same::value_type>::value); +// static_assert(std::is_same::type>::value); typedef typename internal_np::Lookup_named_param_def< internal_np::vertex_normal_map_t, NamedParameters, diff --git a/BGL/include/CGAL/boost/graph/IO/STL.h b/BGL/include/CGAL/boost/graph/IO/STL.h index 7198d8640aa..d2cb78c4524 100644 --- a/BGL/include/CGAL/boost/graph/IO/STL.h +++ b/BGL/include/CGAL/boost/graph/IO/STL.h @@ -264,7 +264,7 @@ bool write_STL(std::ostream& os, if(get_mode(os) == BINARY) { os << "FileType: Binary "; - const boost::uint32_t N32 = static_cast(faces(g).size()); + const std::uint32_t N32 = static_cast(faces(g).size()); os.write(reinterpret_cast(&N32), sizeof(N32)); for(const face_descriptor f : faces(g)) diff --git a/BGL/include/CGAL/boost/graph/helpers.h b/BGL/include/CGAL/boost/graph/helpers.h index 21644ebf18f..34597b22192 100644 --- a/BGL/include/CGAL/boost/graph/helpers.h +++ b/BGL/include/CGAL/boost/graph/helpers.h @@ -848,12 +848,12 @@ inline std::enable_if_t::value, void> clear_impl(FaceGraph& g) { - while(boost::begin(edges(g))!=boost::end(edges(g))) - remove_edge(*boost::begin(edges(g)), g); - while(boost::begin(faces(g))!=boost::end(faces(g))) - remove_face(*boost::begin(faces(g)), g); - while(boost::begin(vertices(g))!=boost::end(vertices(g))) - remove_vertex(*boost::begin(vertices(g)), g); + while(std::begin(edges(g))!=std::end(edges(g))) + remove_edge(*std::begin(edges(g)), g); + while(std::begin(faces(g))!=std::end(faces(g))) + remove_face(*std::begin(faces(g)), g); + while(std::begin(vertices(g))!=std::end(vertices(g))) + remove_vertex(*std::begin(vertices(g)), g); } template @@ -975,9 +975,9 @@ template void clear(FaceGraph& g) { internal::clear_impl(g); - CGAL_postcondition(std::distance(boost::begin(edges(g)),boost::end(edges(g))) == 0); - CGAL_postcondition(std::distance(boost::begin(vertices(g)),boost::end(vertices(g))) == 0); - CGAL_postcondition(std::distance(boost::begin(faces(g)),boost::end(faces(g))) == 0); + CGAL_postcondition(std::distance(std::begin(edges(g)),std::end(edges(g))) == 0); + CGAL_postcondition(std::distance(std::begin(vertices(g)),std::end(vertices(g))) == 0); + CGAL_postcondition(std::distance(std::begin(faces(g)),std::end(faces(g))) == 0); } /** diff --git a/BGL/include/CGAL/boost/graph/internal/Has_member_clear.h b/BGL/include/CGAL/boost/graph/internal/Has_member_clear.h index 9d0288d1171..c0e284b6574 100644 --- a/BGL/include/CGAL/boost/graph/internal/Has_member_clear.h +++ b/BGL/include/CGAL/boost/graph/internal/Has_member_clear.h @@ -29,7 +29,7 @@ public: }; template -CGAL_CPP17_INLINE constexpr bool Has_member_clear_v = Has_member_clear::value; +inline constexpr bool Has_member_clear_v = Has_member_clear::value; } // internal } // cgal diff --git a/BGL/include/CGAL/boost/graph/properties.h b/BGL/include/CGAL/boost/graph/properties.h index fbe1f2e4513..80b02a191a1 100644 --- a/BGL/include/CGAL/boost/graph/properties.h +++ b/BGL/include/CGAL/boost/graph/properties.h @@ -140,7 +140,7 @@ struct Point_accessor typedef ValueType value_type; typedef Handle key_type; - typedef typename boost::mpl::if_< boost::is_reference, + typedef typename boost::mpl::if_< std::is_reference, ValueType&, ValueType >::type Reference; diff --git a/BGL/include/CGAL/boost/graph/property_maps.h b/BGL/include/CGAL/boost/graph/property_maps.h index c10935e27f2..aab29d9b881 100644 --- a/BGL/include/CGAL/boost/graph/property_maps.h +++ b/BGL/include/CGAL/boost/graph/property_maps.h @@ -15,9 +15,7 @@ #include #include -#include #include -#include namespace CGAL{ @@ -25,7 +23,7 @@ namespace CGAL{ template < class TriangleMesh, class VertexPointMap = typename boost::property_map::type > struct Triangle_from_face_descriptor_map{ - typename boost::remove_const::type* m_tm; + typename std::remove_const_t* m_tm; VertexPointMap m_vpm; Triangle_from_face_descriptor_map() @@ -33,13 +31,13 @@ struct Triangle_from_face_descriptor_map{ {} Triangle_from_face_descriptor_map(TriangleMesh const* tm) - : m_tm( const_cast::type*>(tm) ) + : m_tm( const_cast*>(tm) ) , m_vpm( get(vertex_point, *m_tm) ) {} Triangle_from_face_descriptor_map(TriangleMesh const* tm, VertexPointMap vpm ) - : m_tm(const_cast::type*>(tm)) + : m_tm(const_cast*>(tm)) , m_vpm(vpm) {} @@ -57,7 +55,7 @@ struct Triangle_from_face_descriptor_map{ get(const Triangle_from_face_descriptor_map& pmap, key_type f) { - typename boost::remove_const::type & tm = *(pmap.m_tm); + std::remove_const_t& tm = *(pmap.m_tm); CGAL_precondition(halfedge(f,tm) == next(next(next(halfedge(f,tm),tm),tm),tm)); return value_type( get(pmap.m_vpm, target(halfedge(f,tm),tm)), @@ -70,7 +68,7 @@ struct Triangle_from_face_descriptor_map{ get(const Triangle_from_face_descriptor_map& pmap, const std::pair& f) { - typename boost::remove_const::type & tm = *(pmap.m_tm); + std::remove_const_t & tm = *(pmap.m_tm); CGAL_precondition(halfedge(f.first,tm) == next(next(next(halfedge(f.first,tm),tm),tm),tm)); return value_type( get(pmap.m_vpm, target(halfedge(f.first,tm),tm)), @@ -88,13 +86,13 @@ struct Segment_from_edge_descriptor_map{ {} Segment_from_edge_descriptor_map(PolygonMesh const * pm) - : m_pm( const_cast::type*>(pm) ) + : m_pm( const_cast*>(pm) ) , m_vpm( get(vertex_point, *m_pm) ) {} Segment_from_edge_descriptor_map(PolygonMesh const * pm, VertexPointMap vpm ) - : m_pm( const_cast::type*>(pm) ) + : m_pm( const_cast*>(pm) ) , m_vpm(vpm) {} @@ -106,7 +104,7 @@ struct Segment_from_edge_descriptor_map{ typedef value_type reference; typedef boost::readable_property_map_tag category; //data - typename boost::remove_const::type* m_pm; + std::remove_const_t* m_pm; VertexPointMap m_vpm; //get function for property map @@ -138,16 +136,16 @@ struct One_point_from_face_descriptor_map{ {} One_point_from_face_descriptor_map(PolygonMesh const * g) - : m_pm( const_cast::type*>(g) ) + : m_pm( const_cast*>(g) ) , m_vpm( get(vertex_point, *m_pm) ) {} One_point_from_face_descriptor_map(PolygonMesh const * g, VertexPointMap vpm ) - : m_pm( const_cast::type*>(g) ) + : m_pm( const_cast*>(g) ) , m_vpm(vpm) {} - typename boost::remove_const::type* m_pm; + std::remove_const_t* m_pm; VertexPointMap m_vpm; //classical typedefs @@ -182,12 +180,12 @@ struct Source_point_from_edge_descriptor_map{ {} Source_point_from_edge_descriptor_map(PolygonMesh const * g) - : m_pm( const_cast::type*>(g) ) + : m_pm( const_cast*>(g) ) , m_vpm( get(vertex_point, *m_pm) ) {} Source_point_from_edge_descriptor_map(PolygonMesh const * g, VertexPointMap vpm ) - : m_pm( const_cast::type*>(g) ) + : m_pm( const_cast*>(g) ) , m_vpm(vpm) {} @@ -198,7 +196,7 @@ struct Source_point_from_edge_descriptor_map{ typedef boost::readable_property_map_tag category; //data - typename boost::remove_const::type* m_pm; + std::remove_const_t* m_pm; VertexPointMap m_vpm; //get function for property map diff --git a/BGL/include/CGAL/boost/graph/visitor.h b/BGL/include/CGAL/boost/graph/visitor.h index 085c6ce01d9..f7df1e748b2 100644 --- a/BGL/include/CGAL/boost/graph/visitor.h +++ b/BGL/include/CGAL/boost/graph/visitor.h @@ -14,13 +14,13 @@ #include #include -#include +#include namespace boost { template struct graph_traits< - boost::tuple, boost::reference_wrapper > > + boost::tuple, std::reference_wrapper > > : boost::graph_traits< Graph > { typedef boost::graph_traits Base; @@ -29,20 +29,20 @@ namespace boost template struct graph_traits< - boost::tuple, boost::reference_wrapper > const > + boost::tuple, std::reference_wrapper > const > : boost::graph_traits< Graph > {}; template struct property_map< - boost::tuple, boost::reference_wrapper >, + boost::tuple, std::reference_wrapper >, PropertyTag> : public property_map {}; template struct property_map< - const boost::tuple, boost::reference_wrapper >, + const boost::tuple, std::reference_wrapper >, PropertyTag> : public property_map {}; @@ -52,11 +52,11 @@ namespace boost namespace CGAL { template -boost::tuple, - boost::reference_wrapper > +boost::tuple, + std::reference_wrapper > make_graph_with_visitor(V& v, Graph& g) { - return boost::make_tuple(boost::ref(v), boost::ref(g)); + return boost::make_tuple(std::ref(v), std::ref(g)); } template @@ -67,11 +67,8 @@ public: typedef typename gt::halfedge_descriptor halfedge_descriptor; typedef typename gt::edge_descriptor edge_descriptor; typedef typename gt::vertex_descriptor vertex_descriptor; - - }; - //// OVERLOADS FOR Visitor template @@ -260,119 +257,119 @@ void get(PropertyTag ptag, const Visitor_base& w) template typename boost::graph_traits::vertices_size_type -num_vertices(const boost::tuple, - boost::reference_wrapper >& w) +num_vertices(const boost::tuple, + std::reference_wrapper >& w) { - num_vertices(boost::unwrap_ref(w.get<0>())); - return num_vertices(boost::unwrap_ref(w.get<1>())); + num_vertices(get<0>(w).get()); + return num_vertices(get<1>(w).get()); } template typename boost::graph_traits::edges_size_type -num_edges(const boost::tuple, - boost::reference_wrapper >& w) +num_edges(const boost::tuple, + std::reference_wrapper >& w) { - num_edges(boost::unwrap_ref(w.get<0>())); - return num_edges(boost::unwrap_ref(w.get<1>())); + num_edges(get<0>(w).get()); + return num_edges(get<1>(w).get()); } template typename boost::graph_traits::degree_size_type degree(typename boost::graph_traits::vertex_descriptor v - , const boost::tuple, - boost::reference_wrapper >& w) + , const boost::tuple, + std::reference_wrapper >& w) { - degree(v, boost::unwrap_ref(w.get<0>())); - return degree(v, boost::unwrap_ref(w.get<1>())); + degree(v, get<0>(w).get()); + return degree(v, get<1>(w).get()); } template typename boost::graph_traits::degree_size_type out_degree(typename boost::graph_traits::vertex_descriptor v - , const boost::tuple, - boost::reference_wrapper >& w) + , const boost::tuple, + std::reference_wrapper >& w) { - out_degree(v, boost::unwrap_ref(w.get<0>())); - return out_degree(v, boost::unwrap_ref(w.get<1>())); + out_degree(v, get<0>(w).get()); + return out_degree(v, get<1>(w).get()); } template typename boost::graph_traits::degree_size_type in_degree(typename boost::graph_traits::vertex_descriptor v - , const boost::tuple, - boost::reference_wrapper >& w) + , const boost::tuple, + std::reference_wrapper >& w) { - in_degree(v, boost::unwrap_ref(w.get<0>())); - return in_degree(v, boost::unwrap_ref(w.get<1>())); + in_degree(v, get<0>(w).get()); + return in_degree(v, get<1>(w).get()); } template typename boost::graph_traits::vertex_descriptor source(typename boost::graph_traits::edge_descriptor e - , const boost::tuple, - boost::reference_wrapper > & w) + , const boost::tuple, + std::reference_wrapper > & w) { - source(e, boost::unwrap_ref(w.get<0>())); - return source(e, boost::unwrap_ref(w.get<1>())); + source(e, get<0>(w).get()); + return source(e, get<1>(w).get); } template typename boost::graph_traits::vertex_descriptor target(typename boost::graph_traits::edge_descriptor e - , const boost::tuple, - boost::reference_wrapper > & w) + , const boost::tuple, + std::reference_wrapper > & w) { - target(e, boost::unwrap_ref(w.get<0>())); - return target(e, boost::unwrap_ref(w.get<1>())); + target(e, get<0>(w).get()); + return target(e, get<1>(w).get()); } template std::pair::edge_descriptor, bool> edge(typename boost::graph_traits::vertex_descriptor u , typename boost::graph_traits::vertex_descriptor v - , const boost::tuple, - boost::reference_wrapper > & w) + , const boost::tuple, + std::reference_wrapper > & w) { - edge(u, v, boost::unwrap_ref(w.get<0>())); - return edge(u, v, boost::unwrap_ref(w.get<1>())); + edge(u, v, get<0>(w).get()); + return edge(u, v, get<1>(w).get); } template inline CGAL::Iterator_range::vertex_iterator> -vertices(const boost::tuple, - boost::reference_wrapper >& w) +vertices(const boost::tuple, + std::reference_wrapper >& w) { - vertices(boost::unwrap_ref(w.get<0>())); - return vertices(boost::unwrap_ref(w.get<1>())); + vertices(get<0>(w).get()); + return vertices(get<1>(w).get()); } template inline CGAL::Iterator_range::edge_iterator> -edges(const boost::tuple, - boost::reference_wrapper >& w) +edges(const boost::tuple, + std::reference_wrapper >& w) { - edges(boost::unwrap_ref(w.get<0>())); - return edges(boost::unwrap_ref(w.get<1>())); + edges(get<0>(w).get()); + return edges(get<1>(w).get()); } template inline CGAL::Iterator_range::in_edge_iterator> in_edges(typename boost::graph_traits::vertex_descriptor u - , const boost::tuple, - boost::reference_wrapper >& w) + , const boost::tuple, + std::reference_wrapper >& w) { - in_edges(u, boost::unwrap_ref(w.get<0>())); - return in_edges(u, boost::unwrap_ref(w.get<1>())); + in_edges(u, get<0>(w).get()); + return in_edges(u, get<1>(w).get()); } template inline CGAL::Iterator_range::out_edge_iterator> out_edges(typename boost::graph_traits::vertex_descriptor u - , const boost::tuple, - boost::reference_wrapper >& w) + , const boost::tuple, + std::reference_wrapper >& w) { - out_edges(u, boost::unwrap_ref(w.get<0>())); - return out_edges(u, boost::unwrap_ref(w.get<1>())); + out_edges(u, get<0>(w).get()); + return out_edges(u, get<1>(w).get()); } // @@ -381,72 +378,72 @@ out_edges(typename boost::graph_traits::vertex_descriptor u template typename boost::graph_traits< Graph >::vertex_descriptor -add_vertex(boost::tuple, - boost::reference_wrapper >& w) +add_vertex(boost::tuple, + std::reference_wrapper >& w) { - add_vertex(boost::unwrap_ref(w.get<0>())); - return add_vertex(boost::unwrap_ref(w.get<1>())); + add_vertex(get<0>(w).get()); + return add_vertex(get<1>(w).get()); } template typename boost::graph_traits< Graph >::vertex_descriptor add_vertex(const typename boost::graph_traits::vertex_property_type& p - , boost::tuple, - boost::reference_wrapper >& w) + , boost::tuple, + std::reference_wrapper >& w) { - add_vertex(p, boost::unwrap_ref(w.get<0>())); - return add_vertex(p, boost::unwrap_ref(w.get<1>())); + add_vertex(p, get<0>(w).get()); + return add_vertex(p, get<1>(w).get()); } template void remove_vertex(typename boost::graph_traits< Graph >::vertex_descriptor v - , boost::tuple, - boost::reference_wrapper >& w) + , boost::tuple, + std::reference_wrapper >& w) { - remove_vertex(v, boost::unwrap_ref(w.get<0>())); - remove_vertex(v, boost::unwrap_ref(w.get<1>())); + remove_vertex(v, get<0>(w).get()); + remove_vertex(v, get<1>(w).get()); } template typename boost::graph_traits< Graph >::edge_descriptor -add_edge(boost::tuple, - boost::reference_wrapper >& w) +add_edge(boost::tuple, + std::reference_wrapper >& w) { - add_edge(boost::unwrap_ref(w.get<0>())); - return add_edge(boost::unwrap_ref(w.get<1>())); + add_edge(get<0>(w).get()); + return add_edge(get<1>(w).get()); } template void remove_edge(typename boost::graph_traits< Graph >::edge_descriptor e -, boost::tuple, - boost::reference_wrapper >& w) +, boost::tuple, + std::reference_wrapper >& w) { - remove_edge(e, boost::unwrap_ref(w.get<0>())); - remove_edge(e, boost::unwrap_ref(w.get<1>())); + remove_edge(e, get<0>(w).get()); + remove_edge(e, get<1>(w).get()); } template void set_target(typename boost::graph_traits< Graph >::halfedge_descriptor h1 , typename boost::graph_traits< Graph >::vertex_descriptor v -, boost::tuple, - boost::reference_wrapper >& w) +, boost::tuple, + std::reference_wrapper >& w) { - set_target(h1, v, boost::unwrap_ref(w.get<0>())); - set_target(h1, v, boost::unwrap_ref(w.get<1>())); + set_target(h1, v, get<0>(w).get()); + set_target(h1, v, get<1>(w).get()); } template void set_next(typename boost::graph_traits< Graph >::halfedge_descriptor h1 , typename boost::graph_traits< Graph >::halfedge_descriptor h2 - , boost::tuple, - boost::reference_wrapper >& w) + , boost::tuple, + std::reference_wrapper >& w) { - set_next(h1, h2, boost::unwrap_ref(w.get<0>())); - set_next(h1, h2, boost::unwrap_ref(w.get<1>())); + set_next(h1, h2, get<0>(w).get()); + set_next(h1, h2, get<1>(w).get()); } // @@ -454,65 +451,65 @@ set_next(typename boost::graph_traits< Graph >::halfedge_descriptor h1 // template typename boost::graph_traits< Graph >::face_descriptor -add_face(boost::tuple, - boost::reference_wrapper >& w) +add_face(boost::tuple, + std::reference_wrapper >& w) { - add_face(boost::unwrap_ref(w.get<0>())); - return add_face(boost::unwrap_ref(w.get<1>())); + add_face(get<0>(w).get()); + return add_face(get<1>(w).get()); } template typename boost::graph_traits< Graph >::face_descriptor add_face(InputIterator begin, InputIterator end, - boost::tuple, - boost::reference_wrapper >& w) + boost::tuple, + std::reference_wrapper >& w) { - add_face(begin, end, boost::unwrap_ref(w.get<0>())); - return add_face(begin, end, boost::unwrap_ref(w.get<1>())); + add_face(begin, end, get<0>(w).get()); + return add_face(begin, end, get<1>(w).get()); } template void remove_face(typename boost::graph_traits< Graph >::face_descriptor f -, boost::tuple, -boost::reference_wrapper >& w) +, boost::tuple, +std::reference_wrapper >& w) { - remove_face(f, boost::unwrap_ref(w.get<0>())); - return remove_face(f, boost::unwrap_ref(w.get<1>())); + remove_face(f, get<0>(w).get()); + return remove_face(f, get<1>(w).get()); } template void set_face(typename boost::graph_traits< Graph >::halfedge_descriptor h , typename boost::graph_traits< Graph >::face_descriptor f -, const boost::tuple, -boost::reference_wrapper >& w) +, const boost::tuple, +std::reference_wrapper >& w) { - set_face(h, f, boost::unwrap_ref(w.get<0>())); - set_face(h, f, boost::unwrap_ref(w.get<1>())); + set_face(h, f, get<0>(w).get()); + set_face(h, f, get<1>(w).get()); } template void set_halfedge(typename boost::graph_traits< Graph >::face_descriptor f , typename boost::graph_traits< Graph >::halfedge_descriptor h -, boost::tuple, -boost::reference_wrapper >& w) +, boost::tuple, +std::reference_wrapper >& w) { - set_halfedge(f, h, boost::unwrap_ref(w.get<0>())); - set_halfedge(f, h, boost::unwrap_ref(w.get<1>())); + set_halfedge(f, h, get<0>(w).get()); + set_halfedge(f, h, get<1>(w).get()); } template void set_halfedge(typename boost::graph_traits< Graph >::vertex_descriptor v , typename boost::graph_traits< Graph >::halfedge_descriptor h -, const boost::tuple, -boost::reference_wrapper >& w) +, const boost::tuple, +std::reference_wrapper >& w) { - set_halfedge(v, h, boost::unwrap_ref(w.get<0>())); - set_halfedge(v, h, boost::unwrap_ref(w.get<1>())); + set_halfedge(v, h, get<0>(w).get()); + set_halfedge(v, h, get<1>(w).get()); } // @@ -521,31 +518,31 @@ boost::reference_wrapper >& w) template typename boost::graph_traits< Graph >::edge_descriptor edge(typename boost::graph_traits< Graph >::halfedge_descriptor h -, const boost::tuple, - boost::reference_wrapper >& w) +, const boost::tuple, + std::reference_wrapper >& w) { - edge(h, boost::unwrap_ref(w.get<0>())); - return edge(h, boost::unwrap_ref(w.get<1>())); + edge(h, get<0>(w).get()); + return edge(h, get<1>(w).get()); } template typename boost::graph_traits< Graph >::halfedge_descriptor halfedge(typename boost::graph_traits< Graph >::edge_descriptor e -, const boost::tuple, - boost::reference_wrapper >& w) +, const boost::tuple, + std::reference_wrapper >& w) { - halfedge(e, boost::unwrap_ref(w.get<0>())); - return halfedge(e, boost::unwrap_ref(w.get<1>())); + halfedge(e, get<0>(w).get()); + return halfedge(e, get<1>(w).get()); } template typename boost::graph_traits< Graph >::halfedge_descriptor halfedge(typename boost::graph_traits< Graph >::vertex_descriptor v -, const boost::tuple, - boost::reference_wrapper >& w) +, const boost::tuple, + std::reference_wrapper >& w) { - halfedge(v, boost::unwrap_ref(w.get<0>())); - return halfedge(v, boost::unwrap_ref(w.get<1>())); + halfedge(v, get<0>(w).get()); + return halfedge(v, get<1>(w).get()); } template @@ -553,58 +550,58 @@ std::pair< typename boost::graph_traits< Graph >::halfedge_descriptor , bool> halfedge(typename boost::graph_traits< Graph >::vertex_descriptor u , typename boost::graph_traits< Graph >::vertex_descriptor v - , const boost::tuple, - boost::reference_wrapper >& w) + , const boost::tuple, + std::reference_wrapper >& w) { - halfedge(u, v, boost::unwrap_ref(w.get<0>())); - return halfedge(u, v, boost::unwrap_ref(w.get<1>())); + halfedge(u, v, get<0>(w).get()); + return halfedge(u, v, get<1>(w).get()); } template typename boost::graph_traits< Graph >::halfedge_descriptor opposite(typename boost::graph_traits< Graph >::halfedge_descriptor h -, const boost::tuple, - boost::reference_wrapper >& w) +, const boost::tuple, + std::reference_wrapper >& w) { - opposite(h, boost::unwrap_ref(w.get<0>())); - return opposite(h, boost::unwrap_ref(w.get<1>())); + opposite(h, get<0>(w).get()); + return opposite(h, get<1>(w).get()); } template typename boost::graph_traits< Graph >::vertex_descriptor source(typename boost::graph_traits< Graph >::halfedge_descriptor h -, const boost::tuple, - boost::reference_wrapper >& w) +, const boost::tuple, + std::reference_wrapper >& w) { - source(h, boost::unwrap_ref(w.get<0>())); - return source(h, boost::unwrap_ref(w.get<1>())); + source(h, get<0>(w).get()); + return source(h, get<1>(w).get()); } template typename boost::graph_traits< Graph >::vertex_descriptor target(typename boost::graph_traits< Graph >::halfedge_descriptor h -, const boost::tuple, boost::reference_wrapper >& w) +, const boost::tuple, std::reference_wrapper >& w) { - target(h, boost::unwrap_ref(w.get<0>())); - return target(h, boost::unwrap_ref(w.get<1>())); + target(h, get<0>(w).get()); + return target(h, get<1>(w).get()); } template typename boost::graph_traits< Graph >::halfedge_descriptor next(typename boost::graph_traits< Graph >::halfedge_descriptor outedge -, const boost::tuple, boost::reference_wrapper >& w) +, const boost::tuple, std::reference_wrapper >& w) { - next(outedge, boost::unwrap_ref(w.get<0>())); - return next(outedge, boost::unwrap_ref(w.get<1>())); + next(outedge, get<0>(w).get()); + return next(outedge, get<1>(w).get()); } template typename boost::graph_traits< Graph >::halfedge_descriptor prev(typename boost::graph_traits< Graph >::halfedge_descriptor outedge -, const boost::tuple, boost::reference_wrapper >& w) +, const boost::tuple, std::reference_wrapper >& w) { - prev(outedge, boost::unwrap_ref(w.get<0>())); - return prev(outedge, boost::unwrap_ref(w.get<1>())); + prev(outedge, get<0>(w).get()); + return prev(outedge, get<1>(w).get()); } // @@ -612,73 +609,73 @@ prev(typename boost::graph_traits< Graph >::halfedge_descriptor outedge // template CGAL::Iterator_range::halfedge_iterator> -halfedges(const boost::tuple, boost::reference_wrapper >& w) +halfedges(const boost::tuple, std::reference_wrapper >& w) { - halfedges(boost::unwrap_ref(w.get<0>())); - return halfedges(boost::unwrap_ref(w.get<1>())); + halfedges(get<0>(w).get()); + return halfedges(get<1>(w).get()); } template typename boost::graph_traits< Graph >::halfedges_size_type -num_halfedges(const boost::tuple, boost::reference_wrapper >& w) +num_halfedges(const boost::tuple, std::reference_wrapper >& w) { - num_halfedges(boost::unwrap_ref(w.get<0>())); - return num_halfedges(boost::unwrap_ref(w.get<1>())); + num_halfedges(get<0>(w).get()); + return num_halfedges(get<1>(w).get()); } // Graph template typename boost::graph_traits< Graph >::face_descriptor face(typename boost::graph_traits< Graph >::halfedge_descriptor h -, const boost::tuple, boost::reference_wrapper >& w) +, const boost::tuple, std::reference_wrapper >& w) { - face(h, boost::unwrap_ref(w.get<0>())); - return face(h, boost::unwrap_ref(w.get<1>())); + face(h, get<0>(w).get()); + return face(h, get<1>(w).get()); } template typename boost::graph_traits< Graph >::halfedge_descriptor halfedge(typename boost::graph_traits< Graph >::face_descriptor f -, const boost::tuple, boost::reference_wrapper >& w) +, const boost::tuple, std::reference_wrapper >& w) { - halfedge(f, boost::unwrap_ref(w.get<0>())); - return halfedge(f, boost::unwrap_ref(w.get<1>())); + halfedge(f, get<0>(w).get()); + return halfedge(f, get<1>(w).get()); } template inline CGAL::Iterator_range::face_iterator > -faces(const boost::tuple, boost::reference_wrapper >& w) +faces(const boost::tuple, std::reference_wrapper >& w) { - faces(boost::unwrap_ref(w.get<0>())); - return faces(boost::unwrap_ref(w.get<1>())); + faces(get<0>(w).get()); + return faces(get<1>(w).get()); } template typename boost::graph_traits::faces_size_type -num_faces(const boost::tuple, - boost::reference_wrapper >& w) +num_faces(const boost::tuple, + std::reference_wrapper >& w) { - num_faces(boost::unwrap_ref(w.get<0>())); - return num_faces(boost::unwrap_ref(w.get<1>())); + num_faces(get<0>(w).get()); + return num_faces(get<1>(w).get()); } template -bool is_valid(const boost::tuple, - boost::reference_wrapper >& w +bool is_valid(const boost::tuple, + std::reference_wrapper >& w , bool verbose = false) { - is_valid(boost::unwrap_ref(w.get<0>()), verbose); - return is_valid(boost::unwrap_ref(w.get<1>()), verbose); + is_valid(get<0>(w).get(), verbose); + return is_valid(get<1>(w).get(), verbose); } template typename boost::property_map< Graph, PropertyTag >::type get(PropertyTag ptag, - const boost::tuple, - boost::reference_wrapper >& w) + const boost::tuple, + std::reference_wrapper >& w) { - get(ptag, boost::unwrap_ref(w.get<0>())); - return get(ptag, boost::unwrap_ref(w.get<1>())); + get(ptag, get<0>(w).get()); + return get(ptag, get<1>(w).get()); } }//end namespace CGAL diff --git a/BGL/test/BGL/test_Euler_operations.cpp b/BGL/test/BGL/test_Euler_operations.cpp index 4c2ade85ea1..fe7c3275dd1 100644 --- a/BGL/test/BGL/test_Euler_operations.cpp +++ b/BGL/test/BGL/test_Euler_operations.cpp @@ -270,8 +270,8 @@ join_vertex_interior_test() assert(CGAL::internal::exact_num_faces(f.m) == 2); assert(CGAL::internal::exact_num_vertices(f.m) == 5); assert(CGAL::internal::exact_num_edges(f.m) == 6); - assert(boost::distance(CGAL::halfedges_around_face(halfedge(f.f1, f.m), f.m)) == 3); - assert(boost::distance(CGAL::halfedges_around_face(halfedge(f.f2, f.m), f.m)) == 3); + assert(CGAL::halfedges_around_face(halfedge(f.f1, f.m), f.m).size() == 3); + assert(CGAL::halfedges_around_face(halfedge(f.f2, f.m), f.m).size() == 3); assert(degree(f.x, f.m) == 4); assert(CGAL::is_valid_polygon_mesh(f.m)); } @@ -295,8 +295,8 @@ join_vertex_exterior_test() assert(CGAL::internal::exact_num_faces(f.m) == 2); assert(CGAL::internal::exact_num_vertices(f.m) == 5); assert(CGAL::internal::exact_num_edges(f.m) == 6); - assert(boost::distance(CGAL::halfedges_around_face(halfedge(f.f1, f.m), f.m)) == 4); - assert(boost::distance(CGAL::halfedges_around_face(halfedge(f.f2, f.m), f.m)) == 3); + assert(CGAL::halfedges_around_face(halfedge(f.f1, f.m), f.m).size() == 4); + assert(CGAL::halfedges_around_face(halfedge(f.f2, f.m), f.m).size() == 3); assert(degree(f.y, f.m) == 3); assert(CGAL::is_valid_polygon_mesh(f.m)); } @@ -314,8 +314,8 @@ join_vertex_exterior_test() assert(CGAL::internal::exact_num_faces(f.m) == 2); assert(CGAL::internal::exact_num_vertices(f.m) == 5); assert(CGAL::internal::exact_num_edges(f.m) == 6); - assert(boost::distance(CGAL::halfedges_around_face(halfedge(f.f1, f.m), f.m)) == 4); - assert(boost::distance(CGAL::halfedges_around_face(halfedge(f.f2, f.m), f.m)) == 3); + assert(CGAL::halfedges_around_face(halfedge(f.f1, f.m), f.m).size() == 4); + assert(CGAL::halfedges_around_face(halfedge(f.f2, f.m), f.m).size() == 3); assert(CGAL::is_valid_polygon_mesh(f.m)); assert(degree(f.w, f.m) == 3); @@ -344,8 +344,8 @@ split_vertex() assert(CGAL::is_valid_polygon_mesh(f.m)); assert(CGAL::internal::exact_num_vertices(f.m) == 7); assert(CGAL::internal::exact_num_edges(f.m) == 8); - assert(boost::distance(CGAL::halfedges_around_face(h1, f.m)) == 5); - assert(boost::distance(CGAL::halfedges_around_face(h2, f.m)) == 7); + assert(CGAL::halfedges_around_face(h1, f.m).size() == 5); + assert(CGAL::halfedges_around_face(h2, f.m).size() == 7); } template @@ -371,8 +371,8 @@ split_join_vertex_inverse() assert(CGAL::internal::exact_num_faces(f.m) == 2); assert(CGAL::internal::exact_num_edges(f.m) == 6); assert(CGAL::internal::exact_num_halfedges(f.m) == 12); - assert(boost::distance(CGAL::halfedges_around_face(h1, f.m)) == 3); - assert(boost::distance(CGAL::halfedges_around_face(h2, f.m)) == 3); + assert(CGAL::halfedges_around_face(h1, f.m).size() == 3); + assert(CGAL::halfedges_around_face(h2, f.m).size() == 3); } @@ -476,8 +476,8 @@ test_swap_edges() { Graph g; CGAL::make_tetrahedron(pt,pt,pt,pt,g); - halfedge_descriptor h1 = *std::next(boost::begin(halfedges(g)), i); - halfedge_descriptor h2 = *std::next(boost::begin(halfedges(g)), j); + halfedge_descriptor h1 = *std::next(std::begin(halfedges(g)), i); + halfedge_descriptor h2 = *std::next(std::begin(halfedges(g)), j); CGAL::internal::swap_edges(h1, h2, g); assert(CGAL::is_valid_polygon_mesh(g)); } diff --git a/BGL/test/BGL/test_Face_filtered_graph.cpp b/BGL/test/BGL/test_Face_filtered_graph.cpp index 2bab2e1d83c..5dd6521bb02 100644 --- a/BGL/test/BGL/test_Face_filtered_graph.cpp +++ b/BGL/test/BGL/test_Face_filtered_graph.cpp @@ -37,7 +37,7 @@ void test_halfedge_around_vertex_iterator(const Graph& g) assert(target(*havit, fg) == *vit); // check if we are really moving clockwise - halfedge_around_target_iterator step = boost::next(havit); + halfedge_around_target_iterator step = std::next(havit); if(step != havend) { halfedge_descriptor stepd = *step; assert(stepd == opposite(next(*havit, fg), fg)); diff --git a/BGL/test/BGL/test_Has_member_clear.cpp b/BGL/test/BGL/test_Has_member_clear.cpp index 5a78d9a2d7e..b8adc423eb7 100644 --- a/BGL/test/BGL/test_Has_member_clear.cpp +++ b/BGL/test/BGL/test_Has_member_clear.cpp @@ -19,13 +19,13 @@ struct with_clear_const { int main() { using namespace CGAL::internal; - CGAL_static_assertion(Has_member_clear::value); + static_assert(Has_member_clear::value); - CGAL_static_assertion(!Has_member_clear::value); + static_assert(!Has_member_clear::value); - CGAL_static_assertion(!Has_member_clear::value); + static_assert(!Has_member_clear::value); - CGAL_static_assertion(Has_member_clear::value); + static_assert(Has_member_clear::value); return 0; } diff --git a/BGL/test/BGL/test_Has_member_id.cpp b/BGL/test/BGL/test_Has_member_id.cpp index 6ff478d04c2..7cfec0bf8bd 100644 --- a/BGL/test/BGL/test_Has_member_id.cpp +++ b/BGL/test/BGL/test_Has_member_id.cpp @@ -28,17 +28,17 @@ int main() { using namespace CGAL::internal; - CGAL_static_assertion(!Has_member_id::value); - CGAL_static_assertion(Has_member_id::value); - CGAL_static_assertion(!Has_member_id::value); - CGAL_static_assertion(Has_member_id::value); - CGAL_static_assertion(Has_member_id::value); - CGAL_static_assertion( + static_assert(!Has_member_id::value); + static_assert(Has_member_id::value); + static_assert(!Has_member_id::value); + static_assert(Has_member_id::value); + static_assert(Has_member_id::value); + static_assert( (Has_member_id::Face>::value)); - CGAL_static_assertion(!Has_member_id >::value); - CGAL_static_assertion(Has_member_id >::value); - CGAL_static_assertion(Has_member_id >::value); + static_assert(!Has_member_id >::value); + static_assert(Has_member_id >::value); + static_assert(Has_member_id >::value); return 0; } diff --git a/BGL/test/BGL/test_Properties.cpp b/BGL/test/BGL/test_Properties.cpp index ca63a2f7803..e05a0a7eba5 100644 --- a/BGL/test/BGL/test_Properties.cpp +++ b/BGL/test/BGL/test_Properties.cpp @@ -68,9 +68,9 @@ void test_uniqueness(const Graph&, #endif typename boost::range_iterator::type - begin = boost::begin(range), - begin2 = boost::begin(range), - end = boost::end(range); + begin = std::begin(range), + begin2 = std::begin(range), + end = std::end(range); typedef std::unordered_set id_map; typedef std::pair resultp; @@ -98,7 +98,7 @@ void test_vertex_index_map_uniqueness(const Graph& g, typedef typename CGAL::GetInitializedVertexIndexMap::const_type CVIM; // in the case where the map is passed by NP, its type doesn't depend on whether the mesh is const or not - static_assert((std::is_same::value), "VIM, CVIM must be the same type"); + static_assert(std::is_same::value, "VIM, CVIM must be the same type"); VIM ivim = CGAL::get_initialized_vertex_index_map(g, np); @@ -114,7 +114,7 @@ void test_halfedge_index_map_uniqueness(const Graph& g, typedef typename CGAL::GetInitializedHalfedgeIndexMap::const_type CHIM; // in the case where the map is passed by NP, its type doesn't depend on whether the mesh is const or not - static_assert((std::is_same::value), "HIM, CHIM must be the same type"); + static_assert(std::is_same::value, "HIM, CHIM must be the same type"); HIM ihim = CGAL::get_initialized_halfedge_index_map(g, np); @@ -130,7 +130,7 @@ void test_edge_index_map_uniqueness(const Graph& g, typedef typename CGAL::GetInitializedEdgeIndexMap::const_type CEIM; // in the case where the map is passed by NP, its type doesn't depend on whether the mesh is const or not - static_assert((std::is_same::value), "EIM, CEIM must be the same type"); + static_assert(std::is_same::value, "EIM, CEIM must be the same type"); EIM ieim = CGAL::get_initialized_edge_index_map(g, np); @@ -146,7 +146,7 @@ void test_face_index_map_uniqueness(const Graph& g, typedef typename CGAL::GetInitializedFaceIndexMap::const_type CFIM; // in the case where the map is passed by NP, its type doesn't depend on whether the mesh is const or not - static_assert((std::is_same::value), "FIM, CFIM must be the same type"); + static_assert(std::is_same::value, "FIM, CFIM must be the same type"); FIM ifim = CGAL::get_initialized_face_index_map(g, np); diff --git a/BGL/test/BGL/test_Surface_mesh.cpp b/BGL/test/BGL/test_Surface_mesh.cpp deleted file mode 100644 index f47f4f49f94..00000000000 --- a/BGL/test/BGL/test_Surface_mesh.cpp +++ /dev/null @@ -1,125 +0,0 @@ -#define BOOST_TEST_MODULE graph_traits test -#include -#include - -BOOST_AUTO_TEST_CASE( edges_test ) -{ - edge_iterator eb, ee; - vertex_iterator vb, ve; - - Surface_fixture f; - boost::tie(eb, ee) = edges(f.m); - boost::tie(vb, ve) = vertices(f.m); - BOOST_CHECK(std::distance(eb, ee) == 7); - BOOST_CHECK(std::distance(vb, ve) == 5); - - Cube_fixture cf; - boost::tie(eb, ee) = edges(cf.m); - boost::tie(vb, ve) = vertices(cf.m); - BOOST_CHECK(std::distance(eb, ee) == 18); - BOOST_CHECK(std::distance(vb, ve) == 8); -} - -BOOST_AUTO_TEST_CASE( out_edges_test ) -{ - Surface_fixture f; - - BOOST_CHECK(out_degree(f.u, f.m) == 2); - BOOST_CHECK(out_degree(f.v, f.m) == 4); - std::pair out = out_edges(f.v, f.m); - BOOST_CHECK(std::distance(out.first, out.second) == 4); - out_edge_iterator it = out.first; - while(it != out.second) { - // the source should always be u - BOOST_CHECK(source(*it, f.m) == f.v); - // the target never - BOOST_CHECK(target(*it, f.m) != f.v); - ++it; - } -} - -BOOST_AUTO_TEST_CASE( in_edges_test ) -{ - Surface_fixture f; - BOOST_CHECK(in_degree(f.u, f.m) == 2); - BOOST_CHECK(in_degree(f.x, f.m) == 3); - BOOST_CHECK(in_degree(f.v, f.m) == 4); - std::pair in = in_edges(f.v, f.m); - BOOST_CHECK(std::distance(in.first, in.second) == 4); - - in_edge_iterator it = in.first; - while(it != in.second) { - // the source should never be u - BOOST_CHECK(source(*it, f.m) != f.v); - // the target must always be u - BOOST_CHECK(target(*it, f.m) == f.v); - ++it; - } -} - -BOOST_AUTO_TEST_CASE( in_out_equality ) -{ - // in and out degrees must be equal for each vertex - Cube_fixture f; - for(Sm::Vertex_iterator it = f.m.vertices_begin(); - it != f.m.vertices_end(); ++it) { - BOOST_CHECK(in_degree(*it, f.m) == out_degree(*it, f.m)); - } -} - -BOOST_AUTO_TEST_CASE( face_test ) -{ - Surface_fixture f; - std::pair - enc = enclosure(f.f1, f.m); - BOOST_CHECK(enc.first != enc.second); - BOOST_CHECK(std::distance(enc.first, enc.second) == 3); - enclosure_iterator begin = enc.first; - while(begin != enc.second) - { - BOOST_CHECK(face(*begin, f.m) == f.f1); - ++begin; - } -} - -BOOST_AUTO_TEST_CASE( weight_map_test ) -{ - Surface_fixture f; - Cube_fixture c; - - CGAL::SM_edge_weight_pmap wm1 = boost::get(boost::edge_weight, c.m); - edge_iterator eb, ee; - boost::test_tools::check_is_close_t check_close; - for(boost::tie(eb, ee) = edges(c.m); eb != ee; ++eb) { - BOOST_CHECK( - check_close(wm1[*eb], 2.0, boost::test_tools::percent_tolerance_t(0.00001)) - || check_close(wm1[*eb], 2.82843, boost::test_tools::percent_tolerance_t(0.001))); - } -} - - -BOOST_AUTO_TEST_CASE( vertices_test ) -{ - Surface_fixture f; - - // boost::property_map::type vi_map = get(f.m, boost::vertex_index); - - // vertex_iterator b,e; - - // for(boost::tie(b,e) = vertices(f.m); - // b!= e; - // ++b){ - // std::cout << boost::get(vi_map, *(b)) << std::endl; - // } - - // boost::property_map::type ew_map = get(f.m, boost::edge_weight); - - // edge_iterator be, ee; - - // for(boost::tie(be,ee) = edges(f.m); - // be!= ee; - // ++be){ - // std::cout << boost::get(ew_map, *(be)) << std::endl; - // } - -} diff --git a/BGL/test/BGL/test_deprecated_io.cpp b/BGL/test/BGL/test_deprecated_io.cpp index 65459a997fd..8c22b9f17df 100644 --- a/BGL/test/BGL/test_deprecated_io.cpp +++ b/BGL/test/BGL/test_deprecated_io.cpp @@ -21,18 +21,18 @@ int main() SM sm_in, sm_out; Point_3 p0(0,0,0), p1(1,0,0), p2(0,1,0); CGAL::make_triangle(p0, p1, p2, sm_out); - bool ok = CGAL::write_off("tmp.off", sm_out); + bool ok = CGAL::write_off("tmp_deprecated.off", sm_out); assert(ok); - ok = CGAL::read_off("tmp.off", sm_in); + ok = CGAL::read_off("tmp_deprecated.off", sm_in); assert(ok); assert(num_vertices(sm_in) == 3 && num_faces(sm_in) == 1); sm_in.clear(); - std::ofstream os("tmp.off"); + std::ofstream os("tmp_deprecated.off"); ok = CGAL::write_off(os, sm_out); assert(ok); os.close(); - std::ifstream is("tmp.off"); + std::ifstream is("tmp_deprecated.off"); ok = CGAL::read_off(is, sm_in); assert(ok); assert(num_vertices(sm_in) == 3 && num_faces(sm_in) == 1); @@ -40,18 +40,18 @@ int main() sm_in.clear(); #ifdef CGAL_USE_VTK //vtk - os.open("tmp.vtp"); + os.open("tmp_deprecated.vtp"); ok = CGAL::write_vtp(os, sm_out); assert(ok); os.close(); - ok = CGAL::IO::read_VTP("tmp.vtp", sm_in); + ok = CGAL::IO::read_VTP("tmp_deprecated.vtp", sm_in); assert(ok); assert(num_vertices(sm_in) == 3 && num_faces(sm_in) == 1); sm_in.clear(); #endif //wrl - os.open("tmp.wrl"); + os.open("tmp_deprecated.wrl"); ok = CGAL::write_wrl(os, sm_out); assert(ok); os.close(); diff --git a/BGL/test/BGL/test_graph_traits.cpp b/BGL/test/BGL/test_graph_traits.cpp index 3d71af5a7c2..08e80ef75c7 100644 --- a/BGL/test/BGL/test_graph_traits.cpp +++ b/BGL/test/BGL/test_graph_traits.cpp @@ -34,7 +34,7 @@ void test_halfedge_around_vertex_iterator(const Graph& g) assert(target(*havit, g) == *vit); // check if we are really moving clockwise - halfedge_around_target_iterator step = boost::next(havit); + halfedge_around_target_iterator step = std::next(havit); if(step != havend) { halfedge_descriptor stepd = *step; assert(stepd == opposite(next(*havit, g), g)); diff --git a/Barycentric_coordinates_2/doc/Barycentric_coordinates_2/Barycentric_coordinates_2.txt b/Barycentric_coordinates_2/doc/Barycentric_coordinates_2/Barycentric_coordinates_2.txt index 72588aec436..b3f13fcf819 100644 --- a/Barycentric_coordinates_2/doc/Barycentric_coordinates_2/Barycentric_coordinates_2.txt +++ b/Barycentric_coordinates_2/doc/Barycentric_coordinates_2/Barycentric_coordinates_2.txt @@ -451,10 +451,10 @@ To fix the problem, we modify the weights \f$w_i\f$ as After the above normalization, this gives us the precise algorithm to compute Wachspress coordinates -but with \f$O(n^2)\f$ performance only. The max speed \f$O(n)\f$ algorithm uses the standard +but with \cgalBigO{n^2} performance only. The max speed \cgalBigO{n} algorithm uses the standard weights \f$w_i\f$. Note that mathematically this modification does not change the coordinates. One should be cautious when using the unnormalized Wachspress weights. In that case, you must choose the -\f$O(n)\f$ type. +\cgalBigO{n} type. It is known that for strictly convex polygons the denominator's zero set of the Wachspress coordinates (\f$W^{wp} = 0~\f$) is a curve, which (in many cases) lies quite @@ -507,10 +507,10 @@ To fix the problem, similarly to the previous subsection, we modify the weights After the above normalization, this yields the precise algorithm to compute discrete harmonic coordinates -but with \f$O(n^2)\f$ performance only. The max speed \f$O(n)\f$ algorithm uses the standard +but with \cgalBigO{n^2} performance only. The max speed \cgalBigO{n} algorithm uses the standard weights \f$w_i\f$. Again, mathematically this modification does not change the coordinates, one should be cautious when using the unnormalized discrete harmonic weights. In that case, -you must choose the \f$O(n)\f$ type. +you must choose the \cgalBigO{n} type. \b Warning: as for Wachspress coordinates, we do not recommend using discrete harmonic coordinates for exterior points, because the curve \f$W^{dh} = 0\f$ may have several components, @@ -563,7 +563,7 @@ After the normalization of these weights as before \f$b_i = \frac{w_i}{W^{mv}}\qquad\f$ with \f$\qquad W^{mv} = \sum_{j=1}^n w_j\f$ -we obtain the max precision \f$O(n^2)\f$ algorithm. The max speed \f$O(n)\f$ algorithm computes the +we obtain the max precision \cgalBigO{n^2} algorithm. The max speed \cgalBigO{n} algorithm computes the weights \f$w_i\f$ using the pseudocode from here. These weights @@ -575,7 +575,7 @@ with \f$\qquad t_i = \frac{\text{det}(d_i, d_{i+1})}{r_ir_{i+1} + d_id_{i+1}}\f$ are also normalized. Note that they are unstable if a query point is closer than \f$\approx 1.0e-10\f$ to the polygon boundary, similarly to Wachspress and discrete harmonic coordinates and one should be cautious when using the unnormalized mean value weights. In that case, you must choose the -\f$O(n)\f$ type. +\cgalBigO{n} type. \anchor compute_hm_coord @@ -654,17 +654,17 @@ The resulting timings for all closed-form coordinates can be found in the figure \cgalFigureBegin{analytic_timings, analytic_timings.png} Time in seconds to compute \f$n\f$ coordinate values for a polygon with \f$n\f$ vertices -at 1 million query points with the max speed \f$O(n)\f$ algorithms (dashed) and +at 1 million query points with the max speed \cgalBigO{n} algorithms (dashed) and the max precision \f$0(n^2)\f$ algorithms (solid) for Wachspress (blue), discrete harmonic (red), and mean value (green) coordinates. \cgalFigureEnd -From the figure above we observe that the \f$O(n^2)\f$ algorithm is as fast -as the \f$O(n)\f$ algorithm if we have a polygon with a small number of vertices. +From the figure above we observe that the \cgalBigO{n^2} algorithm is as fast +as the \cgalBigO{n} algorithm if we have a polygon with a small number of vertices. But as the number of vertices is increased, the linear algorithm outperforms the squared one, as expected. One of the reasons for this behavior is that for a small number of vertices -the multiplications of \f$n-2\f$ elements inside the \f$O(n^2)\f$ algorithm take almost the -same time as the corresponding divisions in the \f$O(n)\f$ algorithm. For a polygon with +the multiplications of \f$n-2\f$ elements inside the \cgalBigO{n^2} algorithm take almost the +same time as the corresponding divisions in the \cgalBigO{n} algorithm. For a polygon with many vertices, these multiplications are substantially slower. To benchmark harmonic coordinates, we used a MacBook Pro 2018 with 2.2 GHz Intel Core i7 processor (6 cores) diff --git a/Boolean_set_operations_2/include/CGAL/Boolean_set_operations_2/Gps_agg_meta_traits.h b/Boolean_set_operations_2/include/CGAL/Boolean_set_operations_2/Gps_agg_meta_traits.h index eeb80bf655d..8a0744933e3 100644 --- a/Boolean_set_operations_2/include/CGAL/Boolean_set_operations_2/Gps_agg_meta_traits.h +++ b/Boolean_set_operations_2/include/CGAL/Boolean_set_operations_2/Gps_agg_meta_traits.h @@ -123,14 +123,14 @@ public: typedef typename Arr::Right_side_category Right_side_category; // a side is either oblivious or open (unbounded) - CGAL_static_assertion((std::is_same::value || - std::is_same::value)); - CGAL_static_assertion((std::is_same::value || - std::is_same::value)); - CGAL_static_assertion((std::is_same::value || - std::is_same::value)); - CGAL_static_assertion((std::is_same::value || - std::is_same::value)); + static_assert(std::is_same::value || + std::is_same::value); + static_assert(std::is_same::value || + std::is_same::value); + static_assert(std::is_same::value || + std::is_same::value); + static_assert(std::is_same::value || + std::is_same::value); typedef typename Arr::Halfedge_handle Halfedge_handle; typedef typename Arr::Vertex_handle Vertex_handle; diff --git a/Boolean_set_operations_2/include/CGAL/Boolean_set_operations_2/Gps_traits_decorator.h b/Boolean_set_operations_2/include/CGAL/Boolean_set_operations_2/Gps_traits_decorator.h index c260e4cf824..d9d6f19c1c9 100644 --- a/Boolean_set_operations_2/include/CGAL/Boolean_set_operations_2/Gps_traits_decorator.h +++ b/Boolean_set_operations_2/include/CGAL/Boolean_set_operations_2/Gps_traits_decorator.h @@ -53,14 +53,14 @@ public: typedef typename Base::Right_side_category Right_side_category; // a side is either oblivious or open (unbounded) - CGAL_static_assertion((std::is_same< Left_side_category, Arr_oblivious_side_tag >::value || - std::is_same< Left_side_category, Arr_open_side_tag >::value)); - CGAL_static_assertion((std::is_same< Bottom_side_category, Arr_oblivious_side_tag >::value || - std::is_same< Bottom_side_category, Arr_open_side_tag >::value)); - CGAL_static_assertion((std::is_same< Top_side_category, Arr_oblivious_side_tag >::value || - std::is_same< Top_side_category, Arr_open_side_tag >::value)); - CGAL_static_assertion((std::is_same< Right_side_category, Arr_oblivious_side_tag >::value || - std::is_same< Right_side_category, Arr_open_side_tag >::value)); + static_assert(std::is_same< Left_side_category, Arr_oblivious_side_tag >::value || + std::is_same< Left_side_category, Arr_open_side_tag >::value); + static_assert(std::is_same< Bottom_side_category, Arr_oblivious_side_tag >::value || + std::is_same< Bottom_side_category, Arr_open_side_tag >::value); + static_assert(std::is_same< Top_side_category, Arr_oblivious_side_tag >::value || + std::is_same< Top_side_category, Arr_open_side_tag >::value); + static_assert(std::is_same< Right_side_category, Arr_oblivious_side_tag >::value || + std::is_same< Right_side_category, Arr_open_side_tag >::value); class Ex_point_2 { diff --git a/Bounding_volumes/doc/Bounding_volumes/CGAL/Approximate_min_ellipsoid_d.h b/Bounding_volumes/doc/Bounding_volumes/CGAL/Approximate_min_ellipsoid_d.h index 33d006577bf..856d1a16929 100644 --- a/Bounding_volumes/doc/Bounding_volumes/CGAL/Approximate_min_ellipsoid_d.h +++ b/Bounding_volumes/doc/Bounding_volumes/CGAL/Approximate_min_ellipsoid_d.h @@ -119,7 +119,7 @@ We implement Khachyian's algorithm for rounding polytopes \cgalCite{cgal:k-rprnm-96}. Internally, we use `double`-arithmetic and (initially a single) Cholesky-decomposition. The algorithm's running time is -\f$ {\cal O}(nd^2(\epsilon^{-1}+\ln d + \ln\ln(n)))\f$, where \f$ n=|P|\f$ and +\cgalBigO{nd^2(\epsilon^{-1}+\ln d + \ln\ln(n))}, where \f$ n=|P|\f$ and \f$ 1+\epsilon\f$ is the desired approximation ratio. \cgalHeading{Example} diff --git a/Bounding_volumes/doc/Bounding_volumes/CGAL/Min_sphere_of_spheres_d.h b/Bounding_volumes/doc/Bounding_volumes/CGAL/Min_sphere_of_spheres_d.h index 8d360443390..fbcd5f02e2d 100644 --- a/Bounding_volumes/doc/Bounding_volumes/CGAL/Min_sphere_of_spheres_d.h +++ b/Bounding_volumes/doc/Bounding_volumes/CGAL/Min_sphere_of_spheres_d.h @@ -76,7 +76,7 @@ We implement two algorithms, the LP-algorithm and a heuristic \cgalCite{msw-sblp-92}. As described in the documentation of concept `MinSphereOfSpheresTraits`, each has its advantages and disadvantages: Our implementation of the LP-algorithm has maximal -expected running time \f$ O(2^d n)\f$, while the heuristic comes without +expected running time \cgalBigO{2^d n}, while the heuristic comes without any complexity guarantee. In particular, the LP-algorithm runs in linear time for fixed dimension \f$ d\f$. (These running times hold for the arithmetic model, so they count the number of operations on diff --git a/Bounding_volumes/doc/Bounding_volumes/CGAL/rectangular_p_center_2.h b/Bounding_volumes/doc/Bounding_volumes/CGAL/rectangular_p_center_2.h index f3baaa625f1..519b3eeb24f 100644 --- a/Bounding_volumes/doc/Bounding_volumes/CGAL/rectangular_p_center_2.h +++ b/Bounding_volumes/doc/Bounding_volumes/CGAL/rectangular_p_center_2.h @@ -245,7 +245,7 @@ must be a model for `RectangularPCenterTraits_2`. \cgalHeading{Implementation} The runtime is linear for \f$ p \in \{2,\,3\}\f$ and -\f$ \mathcal{O}(n \cdot \log n)\f$ for \f$ p = 4\f$ where \f$ n\f$ is the number of +\cgalBigO{n \cdot \log n} for \f$ p = 4\f$ where \f$ n\f$ is the number of input points. These runtimes are worst case optimal. The \f$ 3\f$-center algorithm uses a prune-and-search technique described in \cgalCite{cgal:h-slacr-99}. The \f$ 4\f$-center implementation uses sorted matrix diff --git a/Bounding_volumes/doc/Bounding_volumes/Concepts/MinSphereOfSpheresTraits.h b/Bounding_volumes/doc/Bounding_volumes/Concepts/MinSphereOfSpheresTraits.h index 49b32647f3c..a1a0126cf9e 100644 --- a/Bounding_volumes/doc/Bounding_volumes/Concepts/MinSphereOfSpheresTraits.h +++ b/Bounding_volumes/doc/Bounding_volumes/Concepts/MinSphereOfSpheresTraits.h @@ -79,7 +79,7 @@ The recommended choice is the first, which is a synonym to the one of the other two methods which we consider "the best in practice." In case of `CGAL::LP_algorithm`, the minsphere will be computed using the LP-algorithm \cgalCite{msw-sblp-92}, which in our -implementation has maximal expected running time \f$ O(2^d n)\f$ (in the +implementation has maximal expected running time \cgalBigO{2^d n} (in the number of operations on the number type `FT`). In case of `CGAL::Farthest_first_heuristic`, a simple heuristic will be used instead which seems to work fine in practice, but comes without diff --git a/Box_intersection_d/doc/Box_intersection_d/Box_intersection_d.txt b/Box_intersection_d/doc/Box_intersection_d/Box_intersection_d.txt index 64cead02532..2dcd2db8d30 100644 --- a/Box_intersection_d/doc/Box_intersection_d/Box_intersection_d.txt +++ b/Box_intersection_d/doc/Box_intersection_d/Box_intersection_d.txt @@ -350,12 +350,12 @@ parameter the function switches from the streamed segment-tree algorithm to the two-way-scan algorithm, see \cgalCite{cgal:ze-fsbi-02} for the details. -The streamed segment-tree algorithm needs \f$ O(n \log^d (n) + k)\f$ -worst-case running time and \f$ O(n)\f$ space, where \f$ n\f$ is the number of +The streamed segment-tree algorithm needs \cgalBigO{n \log^d (n) + k} +worst-case running time and \cgalBigO{n} space, where \f$ n\f$ is the number of boxes in both input sequences, \f$ d\f$ the (constant) dimension of the boxes, and \f$ k\f$ the output complexity, i.e., the number of pairwise -intersections of the boxes. The two-way-scan algorithm needs \f$ O(n \log -(n) + l)\f$ worst-case running time and \f$ O(n)\f$ space, where \f$ l\f$ is the +intersections of the boxes. The two-way-scan algorithm needs \cgalBigO{n \log +(n) + l} worst-case running time and \cgalBigO{n} space, where \f$ l\f$ is the number of pairwise overlapping intervals in one dimensions (the dimension where the algorithm is used instead of the segment tree). Note that \f$ l\f$ is not necessarily related to \f$ k\f$ and using the diff --git a/Box_intersection_d/doc/Box_intersection_d/CGAL/box_intersection_d.h b/Box_intersection_d/doc/Box_intersection_d/CGAL/box_intersection_d.h index f9ec7ba1ae1..0f7fd9bccdd 100644 --- a/Box_intersection_d/doc/Box_intersection_d/CGAL/box_intersection_d.h +++ b/Box_intersection_d/doc/Box_intersection_d/CGAL/box_intersection_d.h @@ -77,7 +77,7 @@ namespace CGAL { \cgalHeading{Implementation} The algorithm is trivially testing all pairs and runs therefore in time - \f$ O(nm)\f$ where \f$ n\f$ is the size of the first sequence and \f$ m\f$ is the + \cgalBigO{nm} where \f$ n\f$ is the size of the first sequence and \f$ m\f$ is the size of the second sequence. */ @@ -219,12 +219,12 @@ void box_intersection_all_pairs_d( algorithm to the two-way-scan algorithm, see \cgalCite{cgal:ze-fsbi-02} for the details. - The streamed segment-tree algorithm needs \f$ O(n \log^d (n) + k)\f$ - worst-case running time and \f$ O(n)\f$ space, where \f$ n\f$ is the number of + The streamed segment-tree algorithm needs \cgalBigO{n \log^d (n) + k} + worst-case running time and \cgalBigO{n} space, where \f$ n\f$ is the number of boxes in both input sequences, \f$ d\f$ the (constant) dimension of the boxes, and \f$ k\f$ the output complexity, i.e., the number of pairwise - intersections of the boxes. The two-way-scan algorithm needs \f$ O(n \log - (n) + l)\f$ worst-case running time and \f$ O(n)\f$ space, where \f$ l\f$ is the + intersections of the boxes. The two-way-scan algorithm needs \cgalBigO{n \log + (n) + l} worst-case running time and \cgalBigO{n} space, where \f$ l\f$ is the number of pairwise overlapping intervals in one dimensions (the dimension where the algorithm is used instead of the segment tree). Note that \f$ l\f$ is not necessarily related to \f$ k\f$ and using the @@ -397,7 +397,7 @@ namespace CGAL { \cgalHeading{Implementation} The algorithm is trivially testing all pairs and runs therefore in time - \f$ O(n^2)\f$ where \f$ n\f$ is the size of the input sequence. This algorithm + \cgalBigO{n^2} where \f$ n\f$ is the size of the input sequence. This algorithm does not use the id-number of the boxes. */ diff --git a/Box_intersection_d/include/CGAL/Box_intersection_d/segment_tree.h b/Box_intersection_d/include/CGAL/Box_intersection_d/segment_tree.h index 31b1fb23dd0..43f4061a449 100644 --- a/Box_intersection_d/include/CGAL/Box_intersection_d/segment_tree.h +++ b/Box_intersection_d/include/CGAL/Box_intersection_d/segment_tree.h @@ -326,7 +326,7 @@ public: }; template -CGAL_CPP17_INLINE constexpr bool Has_member_report_v = Has_member_report::value; +inline constexpr bool Has_member_report_v = Has_member_report::value; template inline diff --git a/Box_intersection_d/include/CGAL/box_intersection_d.h b/Box_intersection_d/include/CGAL/box_intersection_d.h index 94752c41462..b1bbe31ada5 100644 --- a/Box_intersection_d/include/CGAL/box_intersection_d.h +++ b/Box_intersection_d/include/CGAL/box_intersection_d.h @@ -63,10 +63,10 @@ void box_intersection_segment_tree_d( const NT sup = Box_intersection_d::box_limits::sup(); #ifndef CGAL_LINKED_WITH_TBB - CGAL_static_assertion_msg (!(boost::is_convertible::value), - "Parallel_tag is enabled but TBB is unavailable."); + static_assert (!std::is_convertible::value, + "Parallel_tag is enabled but TBB is unavailable."); #else // CGAL_LINKED_WITH_TBB - if(boost::is_convertible::value) + if(std::is_convertible::value) { // Here is an illustration for n=2. // diff --git a/Box_intersection_d/test/Box_intersection_d/test_Has_member_report.cpp b/Box_intersection_d/test/Box_intersection_d/test_Has_member_report.cpp index 12f64d1bc11..d3d5368f965 100644 --- a/Box_intersection_d/test/Box_intersection_d/test_Has_member_report.cpp +++ b/Box_intersection_d/test/Box_intersection_d/test_Has_member_report.cpp @@ -18,8 +18,8 @@ struct With_report_as_a_template_member_function { int main() { using CGAL::Box_intersection_d::Has_member_report; - CGAL_static_assertion(!Has_member_report::value); - CGAL_static_assertion(Has_member_report::value); - CGAL_static_assertion(Has_member_report::value); + static_assert(!Has_member_report::value); + static_assert(Has_member_report::value); + static_assert(Has_member_report::value); return EXIT_SUCCESS; } diff --git a/CGAL_ImageIO/include/CGAL/ImageIO/bmptypes.h b/CGAL_ImageIO/include/CGAL/ImageIO/bmptypes.h index c40f95ca378..9c27b948b3d 100644 --- a/CGAL_ImageIO/include/CGAL/ImageIO/bmptypes.h +++ b/CGAL_ImageIO/include/CGAL/ImageIO/bmptypes.h @@ -39,10 +39,10 @@ typedef char CGAL_INT8; typedef short CGAL_INT16; -typedef boost::int32_t CGAL_INT32; +typedef std::int32_t CGAL_INT32; typedef unsigned char CGAL_UINT8; typedef unsigned short CGAL_UINT16; -typedef boost::uint32_t CGAL_UINT32; +typedef std::uint32_t CGAL_UINT32; /***************************************************************************** * diff --git a/CGAL_ImageIO/include/CGAL/Image_3_vtk_interface.h b/CGAL_ImageIO/include/CGAL/Image_3_vtk_interface.h index 57e8555557d..99a7f528f17 100644 --- a/CGAL_ImageIO/include/CGAL/Image_3_vtk_interface.h +++ b/CGAL_ImageIO/include/CGAL/Image_3_vtk_interface.h @@ -55,31 +55,31 @@ struct VTK_type_generator { }; template <> -struct VTK_type_generator { +struct VTK_type_generator { static const int type = VTK_UNSIGNED_CHAR; typedef vtkUnsignedCharArray ArrayType; }; template <> -struct VTK_type_generator { +struct VTK_type_generator { static const int type = VTK_SHORT; typedef vtkShortArray ArrayType; }; template <> -struct VTK_type_generator { +struct VTK_type_generator { static const int type = VTK_UNSIGNED_SHORT; typedef vtkUnsignedShortArray ArrayType; }; template <> -struct VTK_type_generator { +struct VTK_type_generator { static const int type = VTK_INT; typedef vtkIntArray ArrayType; }; template <> -struct VTK_type_generator { +struct VTK_type_generator { static const int type = VTK_UNSIGNED_INT; typedef vtkUnsignedIntArray ArrayType; }; diff --git a/CGAL_ImageIO/include/CGAL/SEP_header.h b/CGAL_ImageIO/include/CGAL/SEP_header.h index 17c40493ef5..9bf345d4c6e 100644 --- a/CGAL_ImageIO/include/CGAL/SEP_header.h +++ b/CGAL_ImageIO/include/CGAL/SEP_header.h @@ -20,7 +20,6 @@ #include #include -#include #include #include #include @@ -106,9 +105,9 @@ namespace CGAL { class SEP_header { - boost::array _n; - boost::array _d; - boost::array _o; + std::array _n; + std::array _d; + std::array _o; SEP_header_aux::String_dict _string_dict; diff --git a/CGAL_ipelets/demo/CGAL_ipelets/pca.cpp b/CGAL_ipelets/demo/CGAL_ipelets/pca.cpp index 5e476893af0..50d96042ba6 100644 --- a/CGAL_ipelets/demo/CGAL_ipelets/pca.cpp +++ b/CGAL_ipelets/demo/CGAL_ipelets/pca.cpp @@ -67,8 +67,8 @@ void pcaIpelet::protected_run(int fn) for (std::list::iterator it=poly_list.begin();it!=poly_list.end();++it) if (it->size()==3){ tri_list.push_back(Kernel::Triangle_2(*(it->vertices_begin()), - *boost::next(it->vertices_begin()), - *boost::next(it->vertices_begin(),2) + *std::next(it->vertices_begin()), + *std::next(it->vertices_begin(),2) )); } else{ diff --git a/CGAL_ipelets/include/CGAL/CGAL_Ipelet_base_v6.h b/CGAL_ipelets/include/CGAL/CGAL_Ipelet_base_v6.h index 1d55bf3269e..48572f24118 100644 --- a/CGAL_ipelets/include/CGAL/CGAL_Ipelet_base_v6.h +++ b/CGAL_ipelets/include/CGAL/CGAL_Ipelet_base_v6.h @@ -317,10 +317,10 @@ public: IpeSegmentSubPath* create_polyline(const iterator first, const iterator last,bool setclose=false) const { - if (boost::next(first)!=last){ + if (std::next(first)!=last){ IpeSegmentSubPath* SSP_ipe = new IpeSegmentSubPath(); IpeVector Prev_pt=IpeVector(CGAL::to_double(first->x()),CGAL::to_double(first->y())) ; - for (iterator it = boost::next(first);it!=last;++it){ + for (iterator it = std::next(first);it!=last;++it){ IpeVector Cur_pt=IpeVector(CGAL::to_double(it->x()),CGAL::to_double(it->y())); SSP_ipe -> AppendSegment(Prev_pt,Cur_pt); Prev_pt=Cur_pt; diff --git a/CGAL_ipelets/include/CGAL/CGAL_Ipelet_base_v7.h b/CGAL_ipelets/include/CGAL/CGAL_Ipelet_base_v7.h index cae6c0794f8..276e5d5c651 100644 --- a/CGAL_ipelets/include/CGAL/CGAL_Ipelet_base_v7.h +++ b/CGAL_ipelets/include/CGAL/CGAL_Ipelet_base_v7.h @@ -329,10 +329,10 @@ public: ipe::Curve* create_polyline(const iterator first, const iterator last,bool setclose=false) const { - if (boost::next(first)!=last){ + if (std::next(first)!=last){ ipe::Curve* SSP_ipe = new ipe::Curve(); ipe::Vector Prev_pt=ipe::Vector(CGAL::to_double(first->x()),CGAL::to_double(first->y())) ; - for (iterator it = boost::next(first);it!=last;++it){ + for (iterator it = std::next(first);it!=last;++it){ ipe::Vector Cur_pt=ipe::Vector(CGAL::to_double(it->x()),CGAL::to_double(it->y())); SSP_ipe -> appendSegment(Prev_pt,Cur_pt); Prev_pt=Cur_pt; diff --git a/Circular_kernel_2/benchmark/DxfArrayBenchmarks/benchmark.h b/Circular_kernel_2/benchmark/DxfArrayBenchmarks/benchmark.h index 1e7db3856c0..6c37f7e6907 100644 --- a/Circular_kernel_2/benchmark/DxfArrayBenchmarks/benchmark.h +++ b/Circular_kernel_2/benchmark/DxfArrayBenchmarks/benchmark.h @@ -267,7 +267,7 @@ private: try{ this->start(); - insert(_pm,ac.begin(),ac.end(),boost::false_type()); + insert(_pm,ac.begin(),ac.end(),std::false_type()); this->stop(); } catch (...) { diff --git a/Circular_kernel_2/benchmark/arrangement_traits/benchmark.h b/Circular_kernel_2/benchmark/arrangement_traits/benchmark.h index 36210feffcb..179ea2b2f82 100644 --- a/Circular_kernel_2/benchmark/arrangement_traits/benchmark.h +++ b/Circular_kernel_2/benchmark/arrangement_traits/benchmark.h @@ -214,7 +214,7 @@ class Bench try{ this->start(); - insert(_pm,ac.begin(),ac.end(),boost::false_type()); + insert(_pm,ac.begin(),ac.end(),std::false_type()); this->stop(); } diff --git a/Circular_kernel_2/benchmark/benchmark.h b/Circular_kernel_2/benchmark/benchmark.h index 9d13d728f65..92ba72909ca 100644 --- a/Circular_kernel_2/benchmark/benchmark.h +++ b/Circular_kernel_2/benchmark/benchmark.h @@ -219,7 +219,7 @@ private: Point_location _pl(_pm); try{ this->start(); - insert(_pm,ac.begin(),ac.end(),boost::false_type()); + insert(_pm,ac.begin(),ac.end(),std::false_type()); this->stop(); } catch (std::exception &e) { this->fail(); diff --git a/Circular_kernel_2/benchmark/benchmark_CK2.cpp b/Circular_kernel_2/benchmark/benchmark_CK2.cpp index 54a4137e4ce..fca08228340 100644 --- a/Circular_kernel_2/benchmark/benchmark_CK2.cpp +++ b/Circular_kernel_2/benchmark/benchmark_CK2.cpp @@ -87,7 +87,7 @@ void do_main(const char *s) { struct rusage before, after; struct timeval utime, stime; getrusage(RUSAGE_SELF,&before); - insert(_pm,ac.begin(),ac.end(),boost::false_type()); + insert(_pm,ac.begin(),ac.end(),std::false_type()); getrusage(RUSAGE_SELF,&after); timersub(&(after.ru_utime),&(before.ru_utime),&utime); timersub(&(after.ru_stime),&(before.ru_stime),&stime); @@ -177,7 +177,7 @@ void do_main(int k) { struct rusage before, after; struct timeval utime, stime; getrusage(RUSAGE_SELF,&before); - insert(_pm,ac.begin(),ac.end(),boost::false_type()); + insert(_pm,ac.begin(),ac.end(),std::false_type()); getrusage(RUSAGE_SELF,&after); timersub(&(after.ru_utime),&(before.ru_utime),&utime); timersub(&(after.ru_stime),&(before.ru_stime),&stime); diff --git a/Circular_kernel_2/benchmark/incremental_insertion/benchmark.h b/Circular_kernel_2/benchmark/incremental_insertion/benchmark.h index 3787adde522..1a251c11978 100644 --- a/Circular_kernel_2/benchmark/incremental_insertion/benchmark.h +++ b/Circular_kernel_2/benchmark/incremental_insertion/benchmark.h @@ -217,7 +217,7 @@ class Bench this->start(); for (typename ArcContainer::const_iterator it=ac.begin(); it != ac.end(); ++it) { - insert(_pm,*it,_pl,boost::false_type()); + insert(_pm,*it,_pl,std::false_type()); }; this->stop(); } diff --git a/Circulator/include/CGAL/circulator.h b/Circulator/include/CGAL/circulator.h index 2b1556218f0..1c111779ef8 100644 --- a/Circulator/include/CGAL/circulator.h +++ b/Circulator/include/CGAL/circulator.h @@ -27,8 +27,6 @@ #include #include -#include - // These are name redefinitions for backwards compatibility // with the pre iterator-traits style adaptors. @@ -193,45 +191,45 @@ template inline void Assert_circulator( const C &) { typedef typename Circulator_traits::category category; CGAL_USE_TYPE(category); - CGAL_static_assertion((boost::is_convertible::value)); + static_assert(std::is_convertible::value); } template inline void Assert_iterator( const I &) { typedef typename Circulator_traits::category category; CGAL_USE_TYPE(category); - CGAL_static_assertion((boost::is_convertible::value)); + static_assert(std::is_convertible::value); } template inline void Assert_input_category( const I &/*i*/) { typedef typename std::iterator_traits::iterator_category category; CGAL_USE_TYPE(category); - CGAL_static_assertion((boost::is_convertible::value)); + static_assert(std::is_convertible::value); } template inline void Assert_output_category( const I &/*i*/) { typedef typename std::iterator_traits::iterator_category category; CGAL_USE_TYPE(category); - CGAL_static_assertion((boost::is_convertible::value)); + static_assert(std::is_convertible::value); } template inline void Assert_forward_category( const IC &/*ic*/) { typedef typename std::iterator_traits::iterator_category category; CGAL_USE_TYPE(category); - CGAL_static_assertion((boost::is_convertible::value)); + static_assert(std::is_convertible::value); } template inline void Assert_bidirectional_category( const IC &/*ic*/) { typedef typename std::iterator_traits::iterator_category category; CGAL_USE_TYPE(category); - CGAL_static_assertion((boost::is_convertible::value)); + static_assert(std::is_convertible::value); } template inline void Assert_random_access_category( const IC &/*ic*/) { typedef typename std::iterator_traits::iterator_category category; CGAL_USE_TYPE(category); - CGAL_static_assertion((boost::is_convertible::value)); + static_assert(std::is_convertible::value); } // The assert at-least-category functions use the following // functions to resolve properly. Note the proper order of the diff --git a/Classification/include/CGAL/Classification/ETHZ/internal/random-forest/forest.hpp b/Classification/include/CGAL/Classification/ETHZ/internal/random-forest/forest.hpp index 4611becf711..4b8bff71481 100644 --- a/Classification/include/CGAL/Classification/ETHZ/internal/random-forest/forest.hpp +++ b/Classification/include/CGAL/Classification/ETHZ/internal/random-forest/forest.hpp @@ -164,7 +164,7 @@ public: f (seed_start, sample_idxes, trees, samples, labels, params.n_in_bag_samples, split_generator); #ifndef CGAL_LINKED_WITH_TBB - CGAL_static_assertion_msg (!(std::is_convertible::value), + static_assert (!(std::is_convertible::value), "Parallel_tag is enabled but TBB is unavailable."); #else if (std::is_convertible::value) diff --git a/Classification/include/CGAL/Classification/Image.h b/Classification/include/CGAL/Classification/Image.h index 924e39bde24..084e9572764 100644 --- a/Classification/include/CGAL/Classification/Image.h +++ b/Classification/include/CGAL/Classification/Image.h @@ -16,6 +16,7 @@ #include #include +#include #define CGAL_CLASSIFICATION_IMAGE_SIZE_LIMIT 100000000 @@ -38,12 +39,15 @@ class Image std::shared_ptr m_sparse; Type m_default; - // Forbid using copy constructor - Image (const Image&) - { - } public: + // Forbid using copy constructor + // Make it public for a strange VC++ std17 boost-1_82 error + // https://github.com/boostorg/core/issues/148 + Image(const Image&) + { + CGAL_assertion(false); + } Image () : m_width(0), m_height(0), m_depth(0) { diff --git a/Classification/include/CGAL/Classification/Local_eigen_analysis.h b/Classification/include/CGAL/Classification/Local_eigen_analysis.h index 33e1d706599..78606ed2749 100644 --- a/Classification/include/CGAL/Classification/Local_eigen_analysis.h +++ b/Classification/include/CGAL/Classification/Local_eigen_analysis.h @@ -265,7 +265,7 @@ public: out.m_content->mean_range = 0.; #ifndef CGAL_LINKED_WITH_TBB - CGAL_static_assertion_msg (!(std::is_convertible::value), + static_assert (!(std::is_convertible::value), "Parallel_tag is enabled but TBB is unavailable."); #else if (std::is_convertible::value) @@ -353,7 +353,7 @@ public: out.m_content->mean_range = 0.; #ifndef CGAL_LINKED_WITH_TBB - CGAL_static_assertion_msg (!(std::is_convertible::value), + static_assert (!(std::is_convertible::value), "Parallel_tag is enabled but TBB is unavailable."); #else if (std::is_convertible::value) @@ -431,7 +431,7 @@ public: #ifndef CGAL_LINKED_WITH_TBB - CGAL_static_assertion_msg (!(std::is_convertible::value), + static_assert (!(std::is_convertible::value), "Parallel_tag is enabled but TBB is unavailable."); #else if (std::is_convertible::value) diff --git a/Classification/include/CGAL/Classification/Sum_of_weighted_features_classifier.h b/Classification/include/CGAL/Classification/Sum_of_weighted_features_classifier.h index 2d30a534a42..7f16459723a 100644 --- a/Classification/include/CGAL/Classification/Sum_of_weighted_features_classifier.h +++ b/Classification/include/CGAL/Classification/Sum_of_weighted_features_classifier.h @@ -898,7 +898,7 @@ private: std::size_t gt = j; #ifndef CGAL_LINKED_WITH_TBB - CGAL_static_assertion_msg (!(std::is_convertible::value), + static_assert (!(std::is_convertible::value), "Parallel_tag is enabled but TBB is unavailable."); #else if (std::is_convertible::value) diff --git a/Combinatorial_map/doc/Combinatorial_map/Combinatorial_map.txt b/Combinatorial_map/doc/Combinatorial_map/Combinatorial_map.txt index 2e36037ea23..ed3c60b63b5 100644 --- a/Combinatorial_map/doc/Combinatorial_map/Combinatorial_map.txt +++ b/Combinatorial_map/doc/Combinatorial_map/Combinatorial_map.txt @@ -297,7 +297,7 @@ Several functions allow to create specific configurations of darts into a combin \subsection ssecadvmarks Boolean Marks -It is often necessary to mark darts, for example to retrieve in O(1) if a given dart was already processed during a specific algorithm, for example, iteration over a given range. Users can also mark specific parts of a combinatorial map (for example mark all the darts belonging to objects having specific semantics). To answer these needs, a `GenericMap` has a certain number of Boolean marks (fixed by the constant \link GenericMap::NB_MARKS `NB_MARKS`\endlink). When one wants to use a Boolean mark, the following methods are available (with `cm` an instance of a combinatorial map): +It is often necessary to mark darts, for example to retrieve in \cgalBigO{1} if a given dart was already processed during a specific algorithm, for example, iteration over a given range. Users can also mark specific parts of a combinatorial map (for example mark all the darts belonging to objects having specific semantics). To answer these needs, a `GenericMap` has a certain number of Boolean marks (fixed by the constant \link GenericMap::NB_MARKS `NB_MARKS`\endlink). When one wants to use a Boolean mark, the following methods are available (with `cm` an instance of a combinatorial map):

  • get a new free mark: `size_type m = cm.`\link GenericMap::get_new_mark `get_new_mark()`\endlink (throws the exception Exception_no_more_available_mark if no mark is available);
  • set mark `m` for a given dart `d0`: `cm.`\link GenericMap::mark `mark(d0,m)`\endlink; @@ -498,7 +498,7 @@ Step 2 defines the onsplit and onmerge dynamic functors. We can see here that wi The next operations will call these functors when 2-cells are split or merged. The \link CombinatorialMap::sew `sew<3>`\endlink operation calls 1 onmerge as two faces are identified; the \link GenericMap::insert_cell_0_in_cell_2 `insert_cell_0_in_cell_2`\endlink operation calls 3 onsplit as one face is split in 4. -Lastly we remove the dynamic onmerge functor (step 7). This is done by initializing the fonctor to a default boost::function. After this initialization, no dynamic merge functor is called when two faces are merged. +Lastly we remove the dynamic onmerge functor (step 7). This is done by initializing the functor to a default boost::function. After this initialization, no dynamic merge functor is called when two faces are merged. \cgalExample{Combinatorial_map/map_3_dynamic_onmerge.cpp} diff --git a/Combinatorial_map/include/CGAL/Cell_iterators.h b/Combinatorial_map/include/CGAL/Cell_iterators.h index b54c12bf0c0..93104ba01e2 100644 --- a/Combinatorial_map/include/CGAL/Cell_iterators.h +++ b/Combinatorial_map/include/CGAL/Cell_iterators.h @@ -82,8 +82,8 @@ namespace CGAL { Ite(amap, adart, amap.get_new_mark()), mcell_mark_number(amap.get_new_mark()) { - CGAL_static_assertion( (std::is_same::value) ); + static_assert(std::is_same::value); CGAL_assertion(amap.is_whole_map_unmarked(mcell_mark_number)); mark_cell(amap, adart, mcell_mark_number); @@ -196,8 +196,8 @@ namespace CGAL { Ite(amap, adart), mmark_number(amap.get_new_mark()) { - CGAL_static_assertion( (std::is_same::value) ); + static_assert(std::is_same::value); CGAL_assertion(amap.is_whole_map_unmarked(mmark_number)); mark_cell(amap, adart, mmark_number); } @@ -303,8 +303,8 @@ namespace CGAL { Base(amap), mmark_number(amap.get_new_mark()) { - CGAL_static_assertion( (std::is_same::value) ); + static_assert(std::is_same::value); CGAL_assertion(amap.is_whole_map_unmarked(mmark_number)); mark_cell(amap, (*this), mmark_number); } diff --git a/Combinatorial_map/include/CGAL/Combinatorial_map.h b/Combinatorial_map/include/CGAL/Combinatorial_map.h index 229a8d1a47d..2141b6e1ab4 100644 --- a/Combinatorial_map/include/CGAL/Combinatorial_map.h +++ b/Combinatorial_map/include/CGAL/Combinatorial_map.h @@ -185,7 +185,7 @@ namespace CGAL { */ Combinatorial_map_base() { - CGAL_static_assertion_msg(Helper::nb_attribs<=dimension+1, + static_assert(Helper::nb_attribs<=dimension+1, "Too many attributes in the tuple Attributes_enabled"); this->init_storage(); @@ -803,7 +803,7 @@ namespace CGAL { void restricted_set_dart_attribute(Dart_descriptor dh, typename Attribute_descriptor::type ah) { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "set_dart_attribute called but i-attributes are disabled."); if ( this->template attribute(dh)==ah ) return; @@ -826,7 +826,7 @@ namespace CGAL { void set_dart_attribute(Dart_descriptor dh, typename Attribute_descriptor::type ah) { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "set_dart_attribute called but i-attributes are disabled."); if ( this->template attribute(dh)==ah ) return; @@ -1154,7 +1154,7 @@ namespace CGAL { } /** Unmark all the darts of the map for a given mark. - * If all the darts are marked or unmarked, this operation takes O(1) + * If all the darts are marked or unmarked, this operation takes \cgalBigO{1} * operations, otherwise it traverses all the darts of the map. * @param amark the given mark. */ @@ -1524,8 +1524,8 @@ namespace CGAL { template < class Ite > std::ostream& display_orbits(std::ostream & aos) const { - CGAL_static_assertion( (std::is_same::value) ); + static_assert(std::is_same::value); unsigned int nb = 0; size_type amark = get_new_mark(); for ( typename Dart_range::const_iterator it1(darts().begin()), @@ -1584,7 +1584,7 @@ namespace CGAL { template typename Attribute_descriptor::type create_attribute(const Args&... args) { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "create_attribute but i-attributes are disabled"); typename Attribute_descriptor::type res= std::get::value> @@ -1602,7 +1602,7 @@ namespace CGAL { template void erase_attribute(typename Attribute_descriptor::type h) { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "erase_attribute but i-attributes are disabled"); std::get::value> (mattribute_containers).erase(h); @@ -1612,7 +1612,7 @@ namespace CGAL { template bool is_attribute_used(typename Attribute_const_descriptor< i >::type ah) const { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "is_attribute_used but i-attributes are disabled"); return std::get::value> (mattribute_containers).is_used(ah); @@ -1622,7 +1622,7 @@ namespace CGAL { template size_type number_of_attributes() const { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "number_of_attributes but i-attributes are disabled"); return std::get::value> (mattribute_containers).size(); @@ -1636,8 +1636,8 @@ namespace CGAL { void set_attribute(Dart_descriptor dh, typename Attribute_descriptor::type ah) { - CGAL_static_assertion(i<=dimension); - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(i<=dimension); + static_assert(Helper::template Dimension_index::value>=0, "set_attribute but i-attributes are disabled"); for ( typename Dart_of_cell_range::iterator it(*this, dh); it.cont(); ++it) @@ -1651,7 +1651,7 @@ namespace CGAL { template typename Attribute_range::type & attributes() { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "attributes but i-attributes are disabled"); return std::get::value> (mattribute_containers); @@ -1660,7 +1660,7 @@ namespace CGAL { template typename Attribute_const_range::type & attributes() const { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "attributes but i-attributes are disabled"); return std::get::value> (mattribute_containers); @@ -1673,7 +1673,7 @@ namespace CGAL { typename Attribute_type::type&)>& onsplit_functor() { - CGAL_static_assertion_msg + static_assert (Helper::template Dimension_index::value>=0, "onsplit_functor but " "i-attributes are disabled"); @@ -1689,7 +1689,7 @@ namespace CGAL { typename Attribute_type::type&)>& onsplit_functor() const { - CGAL_static_assertion_msg + static_assert (Helper::template Dimension_index::value>=0, "onsplit_functor but " "i-attributes are disabled"); @@ -1705,7 +1705,7 @@ namespace CGAL { typename Attribute_type::type&)>& onmerge_functor() { - CGAL_static_assertion_msg + static_assert (Helper::template Dimension_index::value>=0, "onsplit_functor but " "i-attributes are disabled"); @@ -1720,7 +1720,7 @@ namespace CGAL { typename Attribute_type::type&)>& onmerge_functor() const { - CGAL_static_assertion_msg + static_assert (Helper::template Dimension_index::value>=0, "onsplit_functor but " "i-attributes are disabled"); diff --git a/Combinatorial_map/include/CGAL/Combinatorial_map/internal/Combinatorial_map_group_functors.h b/Combinatorial_map/include/CGAL/Combinatorial_map/internal/Combinatorial_map_group_functors.h index 06f3c4f4dc3..2b55a2c21c9 100644 --- a/Combinatorial_map/include/CGAL/Combinatorial_map/internal/Combinatorial_map_group_functors.h +++ b/Combinatorial_map/include/CGAL/Combinatorial_map/internal/Combinatorial_map_group_functors.h @@ -64,9 +64,9 @@ struct Group_nonvoid_attribute_functor_of_dart_run typename CMap::Dart_descriptor dh1, typename CMap::Dart_descriptor dh2) { - CGAL_static_assertion( 1<=i && i<=CMap::dimension ); - CGAL_static_assertion( i!=j && (i!=1 || j!=0) ); - CGAL_static_assertion_msg(CMap::Helper::template + static_assert( 1<=i && i<=CMap::dimension ); + static_assert( i!=j && (i!=1 || j!=0) ); + static_assert(CMap::Helper::template Dimension_index::value>=0, "Group_attribute_functor_of_dart_run but " "i-attributes are disabled"); @@ -90,8 +90,8 @@ struct Group_nonvoid_attribute_functor_of_dart_run typename CMap::Dart_descriptor dh1, typename CMap::Dart_descriptor dh2) { - CGAL_static_assertion(j!=0 && j!=1); - CGAL_static_assertion_msg(CMap::Helper::template + static_assert(j!=0 && j!=1); + static_assert(CMap::Helper::template Dimension_index<0>::value>=0, "Group_attribute_functor_of_dart_run<0> but " "0-attributes are disabled"); @@ -127,7 +127,7 @@ struct Group_nonvoid_attribute_functor_of_dart_run typename CMap::Dart_descriptor dh1, typename CMap::Dart_descriptor dh2) { - CGAL_static_assertion_msg(CMap::Helper::template + static_assert(CMap::Helper::template Dimension_index<0>::value>=0, "Group_attribute_functor_of_dart_run<0> but " "0-attributes are disabled"); @@ -152,7 +152,7 @@ struct Group_nonvoid_attribute_functor_of_dart_run typename CMap::Dart_descriptor dh1, typename CMap::Dart_descriptor dh2) { - CGAL_static_assertion_msg(CMap::Helper::template + static_assert(CMap::Helper::template Dimension_index<0>::value>=0, "Group_attribute_functor_of_dart_run<0> but " "0-attributes are disabled"); @@ -240,9 +240,9 @@ struct Group_nonvoid_attribute_functor_run typename CMap::Dart_descriptor adart1, typename CMap::Dart_descriptor adart2) { - CGAL_static_assertion( 1<=i && i<=CMap::dimension ); - CGAL_static_assertion( i!=j ); - CGAL_static_assertion_msg + static_assert( 1<=i && i<=CMap::dimension ); + static_assert( i!=j ); + static_assert ( CMap::Helper::template Dimension_index::value>=0, "Group_attribute_functor_run but i-attributes are disabled" ); typename CMap::template Attribute_descriptor::type @@ -279,10 +279,10 @@ struct Group_nonvoid_attribute_functor_run typename CMap::Dart_descriptor dh1, typename CMap::Dart_descriptor dh2 ) { - CGAL_static_assertion_msg + static_assert ( CMap::Helper::template Dimension_index<0>::value>=0, "Group_attribute_functor_run<0> but 0-attributes are disabled" ); - CGAL_static_assertion(j!=0 && j!=1); + static_assert(j!=0 && j!=1); typename CMap::template Attribute_descriptor<0>::type a1=CMap::null_descriptor, a2=CMap::null_descriptor; @@ -340,7 +340,7 @@ struct Group_nonvoid_attribute_functor_run typename CMap::Dart_descriptor dh1, typename CMap::Dart_descriptor dh2 ) { - CGAL_static_assertion_msg + static_assert ( CMap::Helper::template Dimension_index<0>::value>=0, "Group_attribute_functor_run<0> but 0-attributes are disabled" ); typename CMap::Dart_descriptor od=amap.other_extremity(dh2); @@ -377,7 +377,7 @@ struct Group_nonvoid_attribute_functor_run typename CMap::Dart_descriptor dh1, typename CMap::Dart_descriptor dh2 ) { - CGAL_static_assertion_msg + static_assert ( CMap::Helper::template Dimension_index<0>::value>=0, "Group_attribute_functor_run<0> but 0-attributes are disabled" ); typename CMap::Dart_descriptor od =amap.other_extremity(dh1); @@ -474,9 +474,9 @@ struct Degroup_nonvoid_attribute_functor_run typename CMap::Dart_descriptor adart1, typename CMap::Dart_descriptor adart2) { - CGAL_static_assertion( i<=CMap::dimension ); - CGAL_static_assertion( i!=j ); - CGAL_static_assertion_msg + static_assert( i<=CMap::dimension ); + static_assert( i!=j ); + static_assert ( CMap::Helper::template Dimension_index::value>=0, "Degroup_attribute_functor_run but i-attributes are disabled" ); @@ -549,7 +549,7 @@ void test_split_attribute_functor_one_dart unsigned int, typename CMap::Hash_function> & found_attributes, typename CMap::size_type mark ) { - CGAL_static_assertion_msg(CMap::Helper::template + static_assert(CMap::Helper::template Dimension_index::value>=0, "Test_split_attribute_functor_one_dart but " "i-attributes are disabled"); @@ -615,9 +615,9 @@ struct Test_split_nonvoid_attribute_functor_run &modified_darts, typename CMap::size_type mark_modified_darts=CMap::INVALID_MARK) { - CGAL_static_assertion( 1<=i && i<=CMap::dimension ); + static_assert( 1<=i && i<=CMap::dimension ); CGAL_assertion( i!=j ); - CGAL_static_assertion_msg(CMap::Helper::template + static_assert(CMap::Helper::template Dimension_index::value>=0, "Test_split_attribute_functor_run but " "i-attributes are disabled"); @@ -658,9 +658,9 @@ struct Test_split_nonvoid_attribute_functor_run &modified_darts2, typename CMap::size_type mark_modified_darts=CMap::INVALID_MARK) { - CGAL_static_assertion( 1<=i && i<=CMap::dimension ); + static_assert( 1<=i && i<=CMap::dimension ); CGAL_assertion( i!=j ); - CGAL_static_assertion_msg(CMap::Helper::template + static_assert(CMap::Helper::template Dimension_index::value>=0, "Test_split_attribute_functor_run but " "i-attributes are disabled"); @@ -720,7 +720,7 @@ struct Test_split_nonvoid_attribute_functor_run typename CMap::size_type mark_modified_darts=CMap::INVALID_MARK) { CGAL_assertion( j!=0 && j!=1 ); - CGAL_static_assertion_msg(CMap::Helper::template + static_assert(CMap::Helper::template Dimension_index<0>::value>=0, "Test_split_attribute_functor_run<0> but " "0-attributes are disabled"); @@ -772,7 +772,7 @@ struct Test_split_nonvoid_attribute_functor_run typename CMap::size_type mark_modified_darts=CMap::INVALID_MARK) { CGAL_assertion( j!=0 && j!=1 ); - CGAL_static_assertion_msg(CMap::Helper::template + static_assert(CMap::Helper::template Dimension_index<0>::value>=0, "Test_split_attribute_functor_run<0> but " "0-attributes are disabled"); @@ -858,7 +858,7 @@ struct Test_split_nonvoid_attribute_functor_run &modified_darts2, typename CMap::size_type mark_modified_darts=CMap::INVALID_MARK) { - CGAL_static_assertion_msg(CMap::Helper::template + static_assert(CMap::Helper::template Dimension_index<0>::value>=0, "Test_split_attribute_functor_run<0> but " "0-attributes are disabled"); diff --git a/Combinatorial_map/include/CGAL/Combinatorial_map/internal/Combinatorial_map_internal_functors.h b/Combinatorial_map/include/CGAL/Combinatorial_map/internal/Combinatorial_map_internal_functors.h index 3e0b147942c..c76a210ae6f 100644 --- a/Combinatorial_map/include/CGAL/Combinatorial_map/internal/Combinatorial_map_internal_functors.h +++ b/Combinatorial_map/include/CGAL/Combinatorial_map/internal/Combinatorial_map_internal_functors.h @@ -220,7 +220,7 @@ struct Test_is_valid_attribute_functor typename CMap::Dart_const_descriptor adart, std::vector& marks, bool& ares) { - CGAL_static_assertion_msg(CMap::Helper::template + static_assert(CMap::Helper::template Dimension_index::value>=0, "Test_is_valid_attribute_functor but " " i-attributes are disabled"); @@ -304,7 +304,7 @@ struct Correct_invalid_attributes_functor typename CMap::Dart_descriptor adart, std::vector& marks) { - CGAL_static_assertion_msg(CMap::Helper::template + static_assert(CMap::Helper::template Dimension_index::value>=0, "Correct_invalid_attributes_functor but " " i-attributes are disabled"); @@ -362,7 +362,7 @@ struct Cleanup_useless_attributes template static void run(CMap& amap) { - CGAL_static_assertion_msg(CMap::Helper::template + static_assert(CMap::Helper::template Dimension_index::value>=0, "Cleanup_useless_attributes but " " i-attributes are disabled"); @@ -707,7 +707,7 @@ struct Test_is_same_attribute_point_functor typename Map1::Dart_const_descriptor dh1, typename Map2::Dart_const_descriptor dh2) { - CGAL_static_assertion( Withpoint1==true && Withpoint2==true ); + static_assert( Withpoint1==true && Withpoint2==true ); if (m1.template attribute(dh1)==Map1::null_descriptor && m2.template attribute(dh2)==Map2::null_descriptor) return true; diff --git a/Combinatorial_map/include/CGAL/Combinatorial_map_basic_operations.h b/Combinatorial_map/include/CGAL/Combinatorial_map_basic_operations.h index b7974062ae0..7cb121ff1d8 100644 --- a/Combinatorial_map/include/CGAL/Combinatorial_map_basic_operations.h +++ b/Combinatorial_map/include/CGAL/Combinatorial_map_basic_operations.h @@ -34,8 +34,8 @@ namespace CGAL typename Map::Dart_const_descriptor adart1, typename Map::Dart_const_descriptor adart2) { - CGAL_static_assertion( (std::is_same::value) ); + static_assert(std::is_same::value); bool found=false; for (Iterator it(amap, adart1); !found && it.cont(); ++it) @@ -57,8 +57,8 @@ namespace CGAL typename Map::Dart_const_descriptor adart, typename Map::size_type amark) { - CGAL_static_assertion( (std::is_same::value) ); + static_assert(std::is_same::value); bool res=true; for ( Iterator it(amap, adart); res && it.cont(); ++it ) @@ -98,8 +98,8 @@ namespace CGAL typename Map::Dart_const_descriptor adart, typename Map::size_type amark) { - CGAL_static_assertion( (std::is_same::value) ); + static_assert(std::is_same::value); CGAL_assertion( (is_whole_orbit_unmarked > (amap, adart, amark)) ); @@ -305,8 +305,8 @@ namespace CGAL typename Map::size_type amark, typename Map::size_type amark2=Map::INVALID_MARK) { - CGAL_static_assertion( (std::is_same::value) ); + static_assert(std::is_same::value); CGAL_assertion( (is_whole_orbit_unmarked > (amap, adart, amark)) ); diff --git a/Combinatorial_map/include/CGAL/Combinatorial_map_iterators_base.h b/Combinatorial_map/include/CGAL/Combinatorial_map_iterators_base.h index 0b2c39bc720..a50266f7659 100644 --- a/Combinatorial_map/include/CGAL/Combinatorial_map_iterators_base.h +++ b/Combinatorial_map/include/CGAL/Combinatorial_map_iterators_base.h @@ -305,8 +305,8 @@ namespace CGAL { typedef typename Map::size_type size_type; - CGAL_static_assertion( (Bi<=Map::dimension && - std::is_same::value) ); + static_assert(Bi<=Map::dimension && + std::is_same::value); public: /// Main constructor. @@ -493,8 +493,8 @@ namespace CGAL { typedef typename Map::size_type size_type; - CGAL_static_assertion( (std::is_same::value) ); + static_assert(std::is_same::value); /// Main constructor. CMap_non_basic_iterator(Map& amap, Dart_descriptor adart1): @@ -579,8 +579,8 @@ namespace CGAL { /// True iff this iterator is basic typedef Tag_false Basic_iterator; - CGAL_static_assertion( (std::is_same::value) ); + static_assert(std::is_same::value); /// Main constructor. CMap_non_basic_iterator(Map& amap, Dart_descriptor adart): diff --git a/Combinatorial_map/include/CGAL/Combinatorial_map_operations.h b/Combinatorial_map/include/CGAL/Combinatorial_map_operations.h index 2ba09b32650..6a7a1b6f271 100644 --- a/Combinatorial_map/include/CGAL/Combinatorial_map_operations.h +++ b/Combinatorial_map/include/CGAL/Combinatorial_map_operations.h @@ -77,7 +77,7 @@ namespace CGAL static size_t run(CMap& amap, typename CMap::Dart_descriptor adart, bool update_attributes) { - CGAL_static_assertion ( 1<=i && i(adart)) ); size_t res = 0; @@ -493,7 +493,7 @@ namespace CGAL static size_t run(CMap& amap, typename CMap::Dart_descriptor adart, bool update_attributes) { - CGAL_static_assertion ( 2<=i && i<=CMap::dimension ); + static_assert ( 2<=i && i<=CMap::dimension ); CGAL_assertion( (amap.template is_contractible(adart)) ); size_t res = 0; diff --git a/Combinatorial_map/include/CGAL/Combinatorial_map_storages.h b/Combinatorial_map/include/CGAL/Combinatorial_map_storages.h index cde06788e0d..8de6b7c1f7f 100644 --- a/Combinatorial_map/include/CGAL/Combinatorial_map_storages.h +++ b/Combinatorial_map/include/CGAL/Combinatorial_map_storages.h @@ -64,7 +64,7 @@ namespace CGAL { typedef typename Dart_container::size_type size_type; typedef std::nullptr_t Null_descriptor_type; - CGAL_CPP17_INLINE static constexpr Null_descriptor_type null_descriptor=nullptr; + inline static constexpr Null_descriptor_type null_descriptor=nullptr; using Type_for_compact_container=void*; @@ -107,7 +107,7 @@ namespace CGAL { template using Attribute_const_handle=Attribute_const_descriptor; - CGAL_CPP17_INLINE static constexpr Null_descriptor_type null_handle=null_descriptor; + inline static constexpr Null_descriptor_type null_handle=null_descriptor; /// Number of marks static const size_type NB_MARKS = 32; @@ -232,7 +232,7 @@ namespace CGAL { template typename Attribute_descriptor::type attribute(Dart_descriptor ADart) { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "attribute called but i-attributes are disabled."); return std::get::value> (ADart->mattribute_descriptors); @@ -241,7 +241,7 @@ namespace CGAL { typename Attribute_const_descriptor::type attribute(Dart_const_descriptor ADart) const { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "attribute called but i-attributes are disabled."); return std::get::value> (ADart->mattribute_descriptors); @@ -252,7 +252,7 @@ namespace CGAL { typename Attribute_descriptor::type copy_attribute (typename Attribute_const_descriptor::type ah) { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "copy_attribute called but i-attributes are disabled."); typename Attribute_descriptor::type res= std::get::value> @@ -467,16 +467,6 @@ namespace CGAL { typename Helper::Attribute_containers mattribute_containers; }; -#ifndef CGAL_CXX17 - template - constexpr typename Combinatorial_map_storage_1::Null_descriptor_type - Combinatorial_map_storage_1::null_descriptor; - - template - constexpr typename Combinatorial_map_storage_1::Null_descriptor_type - Combinatorial_map_storage_1::null_handle; -#endif - } // namespace CGAL #if defined(BOOST_GCC) diff --git a/Combinatorial_map/include/CGAL/Combinatorial_map_storages_with_index.h b/Combinatorial_map/include/CGAL/Combinatorial_map_storages_with_index.h index 584442412c5..f1e3d62cbab 100644 --- a/Combinatorial_map/include/CGAL/Combinatorial_map_storages_with_index.h +++ b/Combinatorial_map/include/CGAL/Combinatorial_map_storages_with_index.h @@ -266,7 +266,7 @@ namespace CGAL { template typename Attribute_descriptor::type attribute(Dart_descriptor ADart) { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "attribute called but i-attributes are disabled."); return std::get::value> (mdarts[ADart].mattribute_descriptors); @@ -275,7 +275,7 @@ namespace CGAL { typename Attribute_const_descriptor::type attribute(Dart_const_descriptor ADart) const { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "attribute called but i-attributes are disabled."); return std::get::value> (mdarts[ADart].mattribute_descriptors); @@ -286,7 +286,7 @@ namespace CGAL { typename Attribute_descriptor::type copy_attribute (typename Attribute_const_descriptor::type ah) { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "copy_attribute called but i-attributes are disabled."); // We need to do a reserve before the emplace in order to avoid a bug of // invalid reference when the container is reallocated. diff --git a/Combinatorial_map/include/CGAL/Dart.h b/Combinatorial_map/include/CGAL/Dart.h index 3308def6103..17ffde4b294 100644 --- a/Combinatorial_map/include/CGAL/Dart.h +++ b/Combinatorial_map/include/CGAL/Dart.h @@ -226,7 +226,7 @@ namespace CGAL { template typename Attribute_descriptor::type attribute() { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "attribute called but i-attributes are disabled."); return std::get::value> (mattribute_descriptors); @@ -234,7 +234,7 @@ namespace CGAL { template typename Attribute_const_descriptor::type attribute() const { - CGAL_static_assertion_msg(Helper::template Dimension_index::value>=0, + static_assert(Helper::template Dimension_index::value>=0, "attribute called but i-attributes are disabled."); return std::get::value> (mattribute_descriptors); diff --git a/Combinatorial_map/include/CGAL/Dart_iterators.h b/Combinatorial_map/include/CGAL/Dart_iterators.h index c73a32b383e..2e552f25950 100644 --- a/Combinatorial_map/include/CGAL/Dart_iterators.h +++ b/Combinatorial_map/include/CGAL/Dart_iterators.h @@ -295,13 +295,13 @@ namespace CGAL { /// Main constructor. CMap_dart_iterator_basic_of_orbit_generic(Map& amap, Dart_descriptor adart): Base(amap, adart) - { CGAL_static_assertion( Bi>=2 && Bi<=Map::dimension ); } + { static_assert( Bi>=2 && Bi<=Map::dimension ); } /// Main constructor. CMap_dart_iterator_basic_of_orbit_generic(Map& amap, Dart_descriptor adart, size_type /*amark*/): Base(amap, adart) - { CGAL_static_assertion( Bi>=2 && Bi<=Map::dimension ); } + { static_assert( Bi>=2 && Bi<=Map::dimension ); } /// Prefix ++ operator. Self& operator++() @@ -346,7 +346,7 @@ namespace CGAL { typedef Tag_false Use_mark; - CGAL_static_assertion( Bi>1 && delta>1 && Bi+delta<=Map::dimension ); + static_assert( Bi>1 && delta>1 && Bi+delta<=Map::dimension ); public: /// Main constructor. @@ -460,7 +460,7 @@ namespace CGAL { typedef Tag_true Use_mark; - CGAL_static_assertion( 2<=Map::dimension ); + static_assert( 2<=Map::dimension ); public: /// Main constructor. @@ -493,7 +493,7 @@ namespace CGAL { typedef Tag_true Use_mark; - CGAL_static_assertion( 2<=Map::dimension ); + static_assert( 2<=Map::dimension ); public: /// Main constructor. @@ -524,7 +524,7 @@ namespace CGAL { typedef Tag_false Use_mark; - CGAL_static_assertion( delta>1 && delta<=Map::dimension ); + static_assert( delta>1 && delta<=Map::dimension ); public: /// Main constructor. @@ -625,7 +625,7 @@ namespace CGAL { typedef Tag_false Use_mark; - CGAL_static_assertion( delta>1 && delta+1<=Map::dimension ); + static_assert( delta>1 && delta+1<=Map::dimension ); public: /// Main constructor. @@ -726,7 +726,7 @@ namespace CGAL { typedef Tag_false Use_mark; - CGAL_static_assertion( Bi>1 && Bi+1<=Map::dimension ); + static_assert( Bi>1 && Bi+1<=Map::dimension ); public: /// Main constructor. @@ -1026,7 +1026,7 @@ namespace CGAL { typedef Tag_true Use_mark; - CGAL_static_assertion( i>1 && i<=Map::dimension+1 ); + static_assert( i>1 && i<=Map::dimension+1 ); public: /// Main constructor. diff --git a/Cone_spanners_2/doc/Cone_spanners_2/Cone_spanners_2.txt b/Cone_spanners_2/doc/Cone_spanners_2/Cone_spanners_2.txt index 8de2f97693d..d21ef3f1aca 100644 --- a/Cone_spanners_2/doc/Cone_spanners_2/Cone_spanners_2.txt +++ b/Cone_spanners_2/doc/Cone_spanners_2/Cone_spanners_2.txt @@ -160,7 +160,7 @@ In constructing Theta graphs, this functor uses the algorithm from Chapter 4 of the book by Narasimhan and Smid \cgalCite{cgal:ns-gsn-07}. Basically, it is a sweep line algorithm and uses a balanced search tree to store the vertices that have already been scanned. -It has the complexity of \f$O(n \log n)\f$, where \f$n\f$ is the number of vertices in the plane. +It has the complexity of \cgalBigO{n \log n}, where \f$n\f$ is the number of vertices in the plane. This complexity has been proved to be optimal. For more details on how to use this `Construct_theta_graph_2` functor to write an application to build Theta graphs, @@ -178,13 +178,13 @@ The functor `Construct_yao_graph_2` has a similar definition as `Construct_theta The way of using these two template parameters is the same as that of `Construct_theta_graph_2`, so please refer to the previous subsection for the details. We note here that construction algorithm for Yao graph -is a slight adaptation of the algorithm for constructing Theta graph, having a complexity of \f$O(n^2)\f$. +is a slight adaptation of the algorithm for constructing Theta graph, having a complexity of \cgalBigO{n^2}. The increase of complexity in this adaptation is because in constructing Theta graph, the searching of the 'closest' node by projection distance can be done by a balanced search tree, but in constructing Yao graph, the searching of the 'closest' node by Euclidean distance cannot be done by a balanced search tree. -Note that an optimal algorithm for constructing Yao graph with a complexity of \f$O(n \log n)\f$ is +Note that an optimal algorithm for constructing Yao graph with a complexity of \cgalBigO{n \log n} is described in \cgalCite{cgal:cht-oacov-90}. However, this algorithm is much more complex to implement than the current algorithm implemented, and it can hardly reuse the codes for constructing Theta graphs, so it is not implemented in this package right now. diff --git a/Convex_decomposition_3/doc/Convex_decomposition_3/Convex_decomposition_3.txt b/Convex_decomposition_3/doc/Convex_decomposition_3/Convex_decomposition_3.txt index 6720620e075..98f1e2e2d6a 100644 --- a/Convex_decomposition_3/doc/Convex_decomposition_3/Convex_decomposition_3.txt +++ b/Convex_decomposition_3/doc/Convex_decomposition_3/Convex_decomposition_3.txt @@ -18,11 +18,11 @@ Minkowski sums of the convex pieces, and unite the pair-wise sums. While it is desirable to have a decomposition into a minimum number of pieces, this problem is known to be NP-hard \cgalCite{c-cpplb-84}. Our -implementation decomposes a Nef polyhedron \f$ N\f$ into \f$ O(r^2)\f$ convex +implementation decomposes a Nef polyhedron \f$ N\f$ into \cgalBigO{r^2} convex pieces, where \f$ r\f$ is the number of edges that have two adjacent facets that span an angle of more than 180 degrees with respect to the interior of the polyhedron. Those edges are also called reflex edges. -The bound of \f$ O(r^2)\f$ convex pieces is worst-case +The bound of \cgalBigO{r^2} convex pieces is worst-case optimal \cgalCite{c-cpplb-84}. \cgalFigureBegin{figverticalDecomposition,two_cubes_all_in_one.png} diff --git a/Convex_decomposition_3/doc/Convex_decomposition_3/PackageDescription.txt b/Convex_decomposition_3/doc/Convex_decomposition_3/PackageDescription.txt index 8d49a1ce844..4d65e689fad 100644 --- a/Convex_decomposition_3/doc/Convex_decomposition_3/PackageDescription.txt +++ b/Convex_decomposition_3/doc/Convex_decomposition_3/PackageDescription.txt @@ -6,7 +6,7 @@ \cgalPkgPicture{Convex_decomposition_3/fig/Convex_decomposition_3-teaser.png} \cgalPkgSummaryBegin \cgalPkgAuthor{Peter Hachenberger} -\cgalPkgDesc{This packages provides a function for decomposing a bounded polyhedron into convex sub-polyhedra. The decomposition yields \f$ O(r^2)\f$ convex pieces, where \f$ r\f$ is the number of edges, whose adjacent facets form an angle of more than 180 degrees with respect to the polyhedron's interior. This bound is worst-case optimal. } +\cgalPkgDesc{This packages provides a function for decomposing a bounded polyhedron into convex sub-polyhedra. The decomposition yields \cgalBigO{r^2} convex pieces, where \f$ r\f$ is the number of edges, whose adjacent facets form an angle of more than 180 degrees with respect to the polyhedron's interior. This bound is worst-case optimal. } \cgalPkgManuals{Chapter_Convex_Decomposition_of_Polyhedra,PkgConvexDecomposition3Ref} \cgalPkgSummaryEnd \cgalPkgShortInfoBegin diff --git a/Convex_decomposition_3/include/CGAL/convex_decomposition_3.h b/Convex_decomposition_3/include/CGAL/convex_decomposition_3.h index 7993309d4d0..08d6750b7fb 100644 --- a/Convex_decomposition_3/include/CGAL/convex_decomposition_3.h +++ b/Convex_decomposition_3/include/CGAL/convex_decomposition_3.h @@ -41,12 +41,12 @@ The function `convex_decomposition_3()` inserts additional facets into the given `Nef_polyhedron_3` `N`, such that each bounded marked volume (the outer volume is unbounded) is subdivided into convex pieces. The modified polyhedron represents a decomposition into -\f$ O(r^2)\f$ convex pieces, where \f$ r\f$ is the number of edges that have two +\cgalBigO{r^2} convex pieces, where \f$ r\f$ is the number of edges that have two adjacent facets that span an angle of more than 180 degrees with respect to the interior of the polyhedron. The worst-case running time of our implementation is -\f$ O(n^2r^4\sqrt[3]{nr^2}\log{(nr)})\f$, where \f$ n\f$ is the complexity of +\cgalBigO{n^2r^4\sqrt[3]{nr^2}\log{(nr)}}, where \f$ n\f$ is the complexity of the polyhedron (the complexity of a `Nef_polyhedron_3` is the sum of its `Vertices`, `Halfedges` and `SHalfedges`) and \f$ r\f$ is the number of reflex edges. diff --git a/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_akl_toussaint.h b/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_akl_toussaint.h index 4df696cd96e..1b22a558868 100644 --- a/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_akl_toussaint.h +++ b/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_akl_toussaint.h @@ -44,7 +44,7 @@ functions that return instances of these types: \cgalHeading{Implementation} This function uses the algorithm of Akl and -Toussaint \cgalCite{at-fcha-78} that requires \f$ O(n \log n)\f$ time for \f$ n\f$ input +Toussaint \cgalCite{at-fcha-78} that requires \cgalBigO{n \log n} time for \f$ n\f$ input points. diff --git a/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_bykat.h b/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_bykat.h index 03ca5875518..6bf670ff5ac 100644 --- a/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_bykat.h +++ b/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_bykat.h @@ -45,7 +45,7 @@ functions that return instances of these types: This function implements the non-recursive variation of Eddy's algorithm \cgalCite{e-nchap-77} described in \cgalCite{b-chfsp-78}. -This algorithm requires \f$ O(n h)\f$ time +This algorithm requires \cgalBigO{n h} time in the worst case for \f$ n\f$ input points with \f$ h\f$ extreme points. */ template diff --git a/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_eddy.h b/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_eddy.h index 9a023d34070..836366e0b90 100644 --- a/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_eddy.h +++ b/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_eddy.h @@ -47,7 +47,7 @@ This function implements Eddy's algorithm \cgalCite{e-nchap-77}, which is the two-dimensional version of the quickhull algorithm \cgalCite{bdh-qach-96}. -This algorithm requires \f$ O(n h)\f$ time +This algorithm requires \cgalBigO{n h} time in the worst case for \f$ n\f$ input points with \f$ h\f$ extreme points. */ diff --git a/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_graham_andrew.h b/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_graham_andrew.h index 20119b4243b..f2225a2fd33 100644 --- a/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_graham_andrew.h +++ b/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_graham_andrew.h @@ -44,7 +44,7 @@ functions that return instances of these types: This function implements Andrew's variant of the Graham scan algorithm \cgalCite{a-aeach-79} and follows the presentation of Mehlhorn -\cgalCite{m-mdscg-84}. This algorithm requires \f$ O(n \log n)\f$ time +\cgalCite{m-mdscg-84}. This algorithm requires \cgalBigO{n \log n} time in the worst case for \f$ n\f$ input points. @@ -101,7 +101,7 @@ functions that return instances of these types: \cgalHeading{Implementation} -This algorithm requires \f$ O(n)\f$ time in the worst case for +This algorithm requires \cgalBigO{n} time in the worst case for \f$ n\f$ input points. \cgalHeading{Example} diff --git a/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_jarvis.h b/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_jarvis.h index 41478fb06f9..e3ad2818c2f 100644 --- a/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_jarvis.h +++ b/Convex_hull_2/doc/Convex_hull_2/CGAL/ch_jarvis.h @@ -44,7 +44,7 @@ functions that return instances of these types: \cgalHeading{Implementation} This function uses the Jarvis march (gift-wrapping) -algorithm \cgalCite{j-ichfs-73}. This algorithm requires \f$ O(n h)\f$ time +algorithm \cgalCite{j-ichfs-73}. This algorithm requires \cgalBigO{n h} time in the worst case for \f$ n\f$ input points with \f$ h\f$ extreme points. */ @@ -97,7 +97,7 @@ functions that return instances of these types: \cgalHeading{Implementation} The function uses the Jarvis march (gift-wrapping) algorithm \cgalCite{j-ichfs-73}. -This algorithm requires \f$ O(n h)\f$ time in the worst +This algorithm requires \cgalBigO{n h} time in the worst case for \f$ n\f$ input points with \f$ h\f$ extreme points \pre `start_p` and `stop_p` are extreme points with respect to diff --git a/Convex_hull_2/doc/Convex_hull_2/CGAL/convex_hull_2.h b/Convex_hull_2/doc/Convex_hull_2/CGAL/convex_hull_2.h index 0e54242c874..20a14e030eb 100644 --- a/Convex_hull_2/doc/Convex_hull_2/CGAL/convex_hull_2.h +++ b/Convex_hull_2/doc/Convex_hull_2/CGAL/convex_hull_2.h @@ -47,9 +47,9 @@ functions that return instances of these types: One of two algorithms is used, depending on the type of iterator used to specify the input points. For input iterators, the algorithm used is that of Bykat \cgalCite{b-chfsp-78}, which -has a worst-case running time of \f$ O(n h)\f$, where \f$ n\f$ is the number of input +has a worst-case running time of \cgalBigO{n h}, where \f$ n\f$ is the number of input points and \f$ h\f$ is the number of extreme points. For all other types of -iterators, the \f$ O(n \log n)\f$ algorithm of of Akl and Toussaint +iterators, the \cgalBigO{n \log n} algorithm of of Akl and Toussaint \cgalCite{at-fcha-78} is used. @@ -128,7 +128,7 @@ functions that return instances of these types: This function uses Andrew's variant of Graham's scan algorithm \cgalCite{a-aeach-79}, \cgalCite{m-mdscg-84}. The algorithm has worst-case running time -of \f$ O(n \log n)\f$ for \f$ n\f$ input points. +of \cgalBigO{n \log n} for \f$ n\f$ input points. */ @@ -192,7 +192,7 @@ functions that return instances of these types: This function uses Andrew's variant of Graham's scan algorithm \cgalCite{a-aeach-79}, \cgalCite{m-mdscg-84}. The algorithm -has worst-case running time of \f$ O(n \log n)\f$ for \f$ n\f$ input points. +has worst-case running time of \cgalBigO{n \log n} for \f$ n\f$ input points. */ template diff --git a/Convex_hull_2/doc/Convex_hull_2/CGAL/convexity_check_2.h b/Convex_hull_2/doc/Convex_hull_2/CGAL/convexity_check_2.h index ae033c8acea..002cd7f66de 100644 --- a/Convex_hull_2/doc/Convex_hull_2/CGAL/convexity_check_2.h +++ b/Convex_hull_2/doc/Convex_hull_2/CGAL/convexity_check_2.h @@ -32,7 +32,7 @@ functions that return instances of these types: \cgalHeading{Implementation} -The algorithm requires \f$ O(n)\f$ time for a set of \f$ n\f$ input points. +The algorithm requires \cgalBigO{n} time for a set of \f$ n\f$ input points. @@ -80,7 +80,7 @@ functions that return instances of these types: \cgalHeading{Implementation} -The algorithm requires \f$ O(n)\f$ time for a set of \f$ n\f$ input points. +The algorithm requires \cgalBigO{n} time for a set of \f$ n\f$ input points. diff --git a/Convex_hull_2/doc/Convex_hull_2/Convex_hull_2.txt b/Convex_hull_2/doc/Convex_hull_2/Convex_hull_2.txt index bca9d0f275f..c07ebc8a8a4 100644 --- a/Convex_hull_2/doc/Convex_hull_2/Convex_hull_2.txt +++ b/Convex_hull_2/doc/Convex_hull_2/Convex_hull_2.txt @@ -52,17 +52,17 @@ class need not be specified and defaults to types and operations defined in the kernel in which the input point type is defined. Given a sequence of \f$ n\f$ input points with \f$ h\f$ extreme points, -the function `convex_hull_2()` uses either the output-sensitive \f$ O(n h)\f$ algorithm of Bykat \cgalCite{b-chfsp-78} -(a non-recursive version of the quickhull \cgalCite{bdh-qach-96} algorithm) or the algorithm of Akl and Toussaint, which requires \f$ O(n \log n)\f$ time +the function `convex_hull_2()` uses either the output-sensitive \cgalBigO{n h} algorithm of Bykat \cgalCite{b-chfsp-78} +(a non-recursive version of the quickhull \cgalCite{bdh-qach-96} algorithm) or the algorithm of Akl and Toussaint, which requires \cgalBigO{n \log n} time in the worst case. The algorithm chosen depends on the kind of iterator used to specify the input points. These two algorithms are also available via the functions `ch_bykat()` and `ch_akl_toussaint()`, respectively. Also available are -the \f$ O(n \log n)\f$ Graham-Andrew scan algorithm \cgalCite{a-aeach-79}, \cgalCite{m-mdscg-84} +the \cgalBigO{n \log n} Graham-Andrew scan algorithm \cgalCite{a-aeach-79}, \cgalCite{m-mdscg-84} (`ch_graham_andrew()`), -the \f$ O(n h)\f$ Jarvis march algorithm \cgalCite{j-ichfs-73} +the \cgalBigO{n h} Jarvis march algorithm \cgalCite{j-ichfs-73} (`ch_jarvis()`), -and Eddy's \f$ O(n h)\f$ algorithm \cgalCite{e-nchap-77} +and Eddy's \cgalBigO{n h} algorithm \cgalCite{e-nchap-77} (`ch_eddy()`), which corresponds to the two-dimensional version of the quickhull algorithm. The linear-time algorithm of Melkman for producing the convex hull of @@ -105,7 +105,7 @@ provide the computation of the counterclockwise sequence of extreme points on the lower hull and upper hull, respectively. The algorithm used in these functions is Andrew's variant of Graham's scan algorithm \cgalCite{a-aeach-79}, \cgalCite{m-mdscg-84}, -which has worst-case running time of \f$ O(n \log n)\f$. +which has worst-case running time of \cgalBigO{n \log n}. There are also functions available for computing certain subsequences of the sequence of extreme points on the convex hull. The function diff --git a/Convex_hull_3/doc/Convex_hull_3/CGAL/convexity_check_3.h b/Convex_hull_3/doc/Convex_hull_3/CGAL/convexity_check_3.h index 7c51293eb3f..cd5e70c7b45 100644 --- a/Convex_hull_3/doc/Convex_hull_3/CGAL/convexity_check_3.h +++ b/Convex_hull_3/doc/Convex_hull_3/CGAL/convexity_check_3.h @@ -16,7 +16,7 @@ vertices of the convex hull). \cgalHeading{Implementation} This function implements the tests described in \cgalCite{mnssssu-cgpvg-96} to -determine convexity and requires \f$ O(e + f)\f$ time for a polyhedron with +determine convexity and requires \cgalBigO{e + f} time for a polyhedron with \f$ e\f$ edges and \f$ f\f$ faces. diff --git a/Convex_hull_3/include/CGAL/Convex_hull_3/dual/halfspace_intersection_3.h b/Convex_hull_3/include/CGAL/Convex_hull_3/dual/halfspace_intersection_3.h index 16a685e08dd..87062e5c29d 100644 --- a/Convex_hull_3/include/CGAL/Convex_hull_3/dual/halfspace_intersection_3.h +++ b/Convex_hull_3/include/CGAL/Convex_hull_3/dual/halfspace_intersection_3.h @@ -30,7 +30,6 @@ #include #include -#include #include namespace CGAL @@ -261,7 +260,7 @@ namespace CGAL // The check is done only if the number type is not float or double because in that // case we know the construction of dual points is not exact CGAL_assertion_msg( - boost::is_floating_point::value || + std::is_floating_point::value || Convex_hull_3::internal::point_inside_convex_polyhedron(P, *origin), "halfspace_intersection_3: origin not in the polyhedron" ); diff --git a/Convex_hull_3/include/CGAL/Convex_hull_traits_3.h b/Convex_hull_3/include/CGAL/Convex_hull_traits_3.h index 4cf555e37b3..e57dc65772e 100644 --- a/Convex_hull_3/include/CGAL/Convex_hull_traits_3.h +++ b/Convex_hull_3/include/CGAL/Convex_hull_traits_3.h @@ -151,7 +151,7 @@ struct GT3_for_CH3 { template ::type::value && + std::is_floating_point::type::value && R_::Has_filtered_predicates_tag::value > > class Convex_hull_traits_3 diff --git a/Convex_hull_3/include/CGAL/Convex_hull_vertex_base_2.h b/Convex_hull_3/include/CGAL/Convex_hull_vertex_base_2.h index 2ec965bb809..cef5f5eeac8 100644 --- a/Convex_hull_3/include/CGAL/Convex_hull_vertex_base_2.h +++ b/Convex_hull_3/include/CGAL/Convex_hull_vertex_base_2.h @@ -18,6 +18,7 @@ #include #include +#include #include @@ -77,7 +78,7 @@ template std::ostream& operator<<(std::ostream &os, const Convex_hull_vertex_base_2& v) { - return os << static_cast(v) << v.point(); + return os << static_cast(v) << IO::serialize(v.point()); } } //namespace CGAL diff --git a/Convex_hull_3/include/CGAL/convex_hull_3.h b/Convex_hull_3/include/CGAL/convex_hull_3.h index 18a11329308..51555a5d57b 100644 --- a/Convex_hull_3/include/CGAL/convex_hull_3.h +++ b/Convex_hull_3/include/CGAL/convex_hull_3.h @@ -42,8 +42,6 @@ #include #include -#include -#include #include #include @@ -149,7 +147,7 @@ namespace internal { //struct to select the default traits class for computing convex hull template< class Point_3, class PolygonMesh = Default, - class Is_floating_point=typename boost::is_floating_point::Kernel::FT>::type, + class Is_floating_point=typename std::is_floating_point::Kernel::FT>::type, class Has_filtered_predicates_tag=typename Kernel_traits::Kernel::Has_filtered_predicates_tag > struct Default_traits_for_Chull_3{ typedef typename Kernel_traits::Kernel type; @@ -157,7 +155,7 @@ struct Default_traits_for_Chull_3{ //FT is a floating point type and Kernel is a filtered kernel template -struct Default_traits_for_Chull_3{ +struct Default_traits_for_Chull_3{ typedef Convex_hull_traits_3< typename Kernel_traits::Kernel, PolygonMesh, Tag_true > type; }; @@ -174,7 +172,7 @@ struct Default_polyhedron_for_Chull_3 >{ template struct Is_cartesian_kernel { - typedef boost::false_type type; + typedef std::false_type type; }; template @@ -235,7 +233,7 @@ public: //interval arithmetic (the protector must be created before using this predicate) //and in case of failure, exact arithmetic is used. template -class Is_on_positive_side_of_plane_3, boost::true_type >{ +class Is_on_positive_side_of_plane_3, std::true_type >{ typedef Simple_cartesian::Type> Exact_K; typedef Simple_cartesian Approx_K; typedef Convex_hull_traits_3 Traits; @@ -613,7 +611,7 @@ partition_outside_sets(const std::list& new_facets, } if(! point_list.empty()){ pending_facets.push_back(f); - f->it = boost::prior(pending_facets.end()); + f->it = std::prev(pending_facets.end()); } else { f->it = pending_facets.end(); } @@ -748,7 +746,7 @@ void non_coplanar_quickhull_3(std::list& points, for(Face_iterator fit = tds.faces_begin(); fit != tds.faces_end(); ++fit){ if (! fit->points.empty()){ pending_facets.push_back(fit); - fit->it = boost::prior(pending_facets.end()); + fit->it = std::prev(pending_facets.end()); } else { fit->it = pending_facets.end(); } diff --git a/Convex_hull_3/test/Convex_hull_3/quick_hull_default_traits.cpp b/Convex_hull_3/test/Convex_hull_3/quick_hull_default_traits.cpp index d1bca0f468f..269c14995bc 100644 --- a/Convex_hull_3/test/Convex_hull_3/quick_hull_default_traits.cpp +++ b/Convex_hull_3/test/Convex_hull_3/quick_hull_default_traits.cpp @@ -23,12 +23,12 @@ using namespace CGAL::Convex_hull_3::internal; int main() { - CGAL_static_assertion( (std::is_same::type>::value) ); - CGAL_static_assertion( (std::is_same::type>::value) ); - CGAL_static_assertion( (std::is_same::type>::value) ); - CGAL_static_assertion( (std::is_same::type>::value) ); - CGAL_static_assertion( (std::is_same::type>::value) ); - CGAL_static_assertion( (std::is_same,Default_traits_for_Chull_3::type>::value) ); - CGAL_static_assertion( (std::is_same, boost::true_type >::Protector,CGAL::Protect_FPU_rounding >::value) ); + static_assert(std::is_same::type>::value); + static_assert(std::is_same::type>::value); + static_assert(std::is_same::type>::value); + static_assert(std::is_same::type>::value); + static_assert(std::is_same::type>::value); + static_assert(std::is_same,Default_traits_for_Chull_3::type>::value); + static_assert(std::is_same, std::true_type >::Protector,CGAL::Protect_FPU_rounding >::value); return 0; } diff --git a/Convex_hull_d/doc/Convex_hull_d/CGAL/Convex_hull_d.h b/Convex_hull_d/doc/Convex_hull_d/CGAL/Convex_hull_d.h index aef8523a7d7..aa1d645b345 100644 --- a/Convex_hull_d/doc/Convex_hull_d/CGAL/Convex_hull_d.h +++ b/Convex_hull_d/doc/Convex_hull_d/CGAL/Convex_hull_d.h @@ -69,7 +69,7 @@ The time and space requirements are input dependent. Let \f$C_1\f$, \f$C_2\f$, \ let \f$ k_i\f$ be the number of facets of \f$ C_i\f$ that are visible from \f$ x\f$ and that are not already facets of \f$ C_{i-1}\f$. -Then the time for inserting \f$ x\f$ is \f$ O(dim \sum_i k_i)\f$ and +Then the time for inserting \f$ x\f$ is \cgalBigO{dim \sum_i k_i} and the number of new simplices constructed during the insertion of \f$x\f$ is the number of facets of the hull which were not already facets of the hull before the insertion. diff --git a/Documentation/doc/CMakeLists.txt b/Documentation/doc/CMakeLists.txt index fdb659ea2b5..415fb56131e 100644 --- a/Documentation/doc/CMakeLists.txt +++ b/Documentation/doc/CMakeLists.txt @@ -241,6 +241,18 @@ else() "#EXTRACT_ALL_NO_DETAILED_IF_EMPTY = NO") endif() +option(CGAL_NO_ADDITIONAL_DETAILS + "Use CGAL special doxygen setting NO_ADDITIONAL_DETAILS." ON) +if(CGAL_NO_ADDITIONAL_DETAILS) + set(CGAL_OPT_NO_ADDITIONAL_DETAILS + "NO_ADDITIONAL_DETAILS = YES") +else() + # The default is NO, so we could leave it out, but it is better to have a commented out placeholder + # this will work for versions with and without the setting. + set(CGAL_OPT_NO_ADDITIONAL_DETAILS + "#NO_ADDITIONAL_DETAILS = NO") +endif() + #we use two directories for the generation/reading of tag files to prevent issues #if the targets are built in parallel set(CGAL_DOC_TAG_GEN_DIR "${CMAKE_BINARY_DIR}/doc_gen_tags") diff --git a/Documentation/doc/Documentation/Developer_manual/Chapter_intro.txt b/Documentation/doc/Documentation/Developer_manual/Chapter_intro.txt index ef2ae5bd276..0f7d11e3f81 100644 --- a/Documentation/doc/Documentation/Developer_manual/Chapter_intro.txt +++ b/Documentation/doc/Documentation/Developer_manual/Chapter_intro.txt @@ -169,7 +169,7 @@ complexity are known. Also, the theoretic interest in efficiency for realistic inputs, as opposed to worst-case situations, is growing \cgalCite{v-ffrim-97}. For practical purposes, insight into the constant factors hidden in the -\f$ O\f$-notation is necessary, especially if there are several competing +\cgalBigO{ }-notation is necessary, especially if there are several competing algorithms. Therefore, different implementations should be supplied if there is diff --git a/Documentation/doc/Documentation/Developer_manual/Chapter_kernels.txt b/Documentation/doc/Documentation/Developer_manual/Chapter_kernels.txt index 30b56687143..78706045ef7 100644 --- a/Documentation/doc/Documentation/Developer_manual/Chapter_kernels.txt +++ b/Documentation/doc/Documentation/Developer_manual/Chapter_kernels.txt @@ -7,7 +7,7 @@ \authors Stefan Schirra The layer of geometry kernels provides -basic geometric entities of constant size\cgalFootnote{In dimension \f$ d\f$, an entity of size \f$ O(d)\f$ is considered to be of constant size.} and +basic geometric entities of constant size\cgalFootnote{In dimension \f$ d\f$, an entity of size \cgalBigO{d} is considered to be of constant size.} and primitive operations on them. Each entity is provided as both a stand-alone class, which is parameterized by a kernel class, and as a type in the kernel class. Each operation in the kernel is provided via diff --git a/Documentation/doc/Documentation/Developer_manual/cmakelist_script.txt b/Documentation/doc/Documentation/Developer_manual/cmakelist_script.txt index 64ce1695e41..7b451bf8178 100644 --- a/Documentation/doc/Documentation/Developer_manual/cmakelist_script.txt +++ b/Documentation/doc/Documentation/Developer_manual/cmakelist_script.txt @@ -31,7 +31,7 @@ linked. Valid options are, for instance, "filesystem" or "program_options". -This options should suffice to create `CMakeLists.txt` script +These options should suffice to create a `CMakeLists.txt` script for most directories containing programs. However, in some special cases, it might still be required to create the script manually, for instance, if some source files/executables need a different linking than diff --git a/Documentation/doc/Documentation/Preliminaries.txt b/Documentation/doc/Documentation/Preliminaries.txt index 1fccdc134f9..2e2ae95e661 100644 --- a/Documentation/doc/Documentation/Preliminaries.txt +++ b/Documentation/doc/Documentation/Preliminaries.txt @@ -39,10 +39,9 @@ If you are using CMake, then you can set the CMake option `CGAL_HAS_NO_THREADS` `TRUE`. In addition to defining the preprocessor macro `CGAL_HAS_NO_THREADS`, it will also avoid CMake to link with the native threads support library on your system. -\section Preliminaries_cc0x C++14 Support +\section Preliminaries_cc0x C++17 Support -After being based on the \CC standard released in 1998 (and later refined in 2003) for a long time, -\cgal is now based on a newer major version of the standard, C++14. +\cgal is based on the version C++17 of the C++ standard. \section preliminaries_secchecks Checks diff --git a/Documentation/doc/Documentation/Third_party.txt b/Documentation/doc/Documentation/Third_party.txt index 2d6382b3c17..d55d10c2cbe 100644 --- a/Documentation/doc/Documentation/Third_party.txt +++ b/Documentation/doc/Documentation/Third_party.txt @@ -6,7 +6,7 @@ \section seccompilers Supported Compilers In order to build a program using \cgal, you need a \cpp compiler -supporting C++14 or later. +supporting C++17 or later. \cgal \cgalReleaseNumber is supported (continuously tested) for the following compilers/operating systems: | Operating System | Compiler | @@ -14,9 +14,9 @@ supporting C++14 or later. | Linux | \gnu `g++` 11.3.0 or later\cgalFootnote{\cgalFootnoteCode{https://gcc.gnu.org/}} | | | `Clang` \cgalFootnote{\cgalFootnoteCode{https://clang.llvm.org/}} compiler version 15.0.7 | | \ms Windows | \gnu `g++` 10.2.1 or later\cgalFootnote{\cgalFootnoteCode{https://gcc.gnu.org/}} | -| | \ms Visual `C++` 14.0, 15.9, 16.10, 17.0 (\visualstudio 2015, 2017, 2019, and 2022)\cgalFootnote{\cgalFootnoteCode{https://visualstudio.microsoft.com/}} | +| | \ms Visual `C++` 15.9, 16.10, 17.0 (\visualstudio 2017, 2019, and 2022)\cgalFootnote{\cgalFootnoteCode{https://visualstudio.microsoft.com/}} | | MacOS X | \gnu `g++` 11.3.0 or later\cgalFootnote{\cgalFootnoteCode{https://gcc.gnu.org/}} | -| | Apple `Clang` compiler versions 10.0.1, and 12.0.5. | +| | Apple `Clang` compiler versions 10.0.1, 12.0.5, and 13.0.0 | diff --git a/Documentation/doc/Documentation/windows.txt b/Documentation/doc/Documentation/windows.txt index c4daa8fc380..d40059d76cd 100644 --- a/Documentation/doc/Documentation/windows.txt +++ b/Documentation/doc/Documentation/windows.txt @@ -3,7 +3,7 @@ \cgalAutoToc \cgal \cgalReleaseNumber is supported for the following \ms Visual `C++` compilers: -14.0, 15.9, 16.0, 17.0 (\visualstudio 2015, 2017, 2019, and 2022). +15.9, 16.0, 17.0 (\visualstudio 2017, 2019, and 2022). \cgal is a library that has mandatory dependencies that must be first installed: \ref thirdpartyBoost and \ref thirdpartyMPFR. diff --git a/Documentation/doc/resources/1.8.13/BaseDoxyfile.in b/Documentation/doc/resources/1.8.13/BaseDoxyfile.in index ae2cc84f6c1..15a863470a2 100644 --- a/Documentation/doc/resources/1.8.13/BaseDoxyfile.in +++ b/Documentation/doc/resources/1.8.13/BaseDoxyfile.in @@ -159,9 +159,9 @@ ALIASES = "cgal=%CGAL" \ "cgalPkgSince{1}=Introduced in: \cgal \1
    " \ "cgalPkgDependsOn{1}=Depends on: \1
    " \ "cgalPkgLicense{1}=License: \1
    " \ - "cgalPkgDemo{2}=Windows Demo: \1
    Common Demo Dlls: dlls
    " \ - "cgalPkgDemo{4}=Windows Demos: \1, \3
    Common Demo Dlls: dlls
    " \ - "cgalPkgDemo{6}=Windows Demos: \1, \3, \5
    Common Demo Dlls: dlls
    " \ + "cgalPkgDemo{2}=Windows demo: \1
    Common demo dlls: dlls
    " \ + "cgalPkgDemo{4}=Windows demos: \1, \3
    Common demo dlls: dlls
    " \ + "cgalPkgDemo{6}=Windows demos: \1, \3, \5
    Common demo dlls: dlls
    " \ "cgalPkgDescriptionEnd=" \ "cgalModifBegin=\htmlonly
    \endhtmlonly \xrefitem Modification \"Modifications\" \"MODIFICATIONS\" " \ "cgalModifEnd=\htmlonly
    \endhtmlonly \latexonly END MODIFICATIONS \endlatexonly" \ @@ -188,7 +188,9 @@ ALIASES = "cgal=%CGAL" \ "cgalParamNEnd=
\htmlonly[block] \endhtmlonly " \ "cgalParamSectionBegin{1}=\cgalParamNBegin{\1}" \ "cgalParamSectionEnd=\cgalParamNEnd" \ - "cgalParamPrecondition{1}=
  • Precondition: \1
  • " + "cgalParamPrecondition{1}=
  • Precondition: \1
  • " \ + "cgalBigO{1}=\f$O(\1)\f$" \ + "cgalBigOLarge{1}=\f$O\left(\1\right)\f$" # Doxygen selects the parser to use depending on the extension of the files it # parses. With this tag you can assign which parser to use for a given @@ -262,7 +264,7 @@ EXTRACT_ALL = YES # the EXTRACT_ALL tag is set to NO. # The default value is: NO. -EXTRACT_ALL_NO_DETAILED_IF_EMPTY = YES +${CGAL_OPT_EXTRACT_ALL_NO_DETAILED_IF_EMPTY} # If the EXTRACT_STATIC tag is set to YES, all static members of a file will be # included in the documentation. diff --git a/Documentation/doc/resources/1.8.13/menu_version.js b/Documentation/doc/resources/1.8.13/menu_version.js index a66903b10fe..f3b20c2fe00 100644 --- a/Documentation/doc/resources/1.8.13/menu_version.js +++ b/Documentation/doc/resources/1.8.13/menu_version.js @@ -6,7 +6,8 @@ var current_version_local = 'master' var all_versions = [ 'master', - '5.6-beta1', + '6.0-beta1', + '5.6', 'latest', '5.5.2', '5.4.4', diff --git a/Documentation/doc/resources/1.9.6/BaseDoxyfile.in b/Documentation/doc/resources/1.9.6/BaseDoxyfile.in index 1cfd0a6ffd9..67b8fd643f3 100644 --- a/Documentation/doc/resources/1.9.6/BaseDoxyfile.in +++ b/Documentation/doc/resources/1.9.6/BaseDoxyfile.in @@ -168,9 +168,9 @@ ALIASES = "cgal=%CGAL" \ "cgalPkgSince{1}=Introduced in: \cgal \1
    " \ "cgalPkgDependsOn{1}=Depends on: \1
    " \ "cgalPkgLicense{1}=License: \1
    " \ - "cgalPkgDemo{2}=Windows Demo: \1
    Common Demo Dlls: dlls
    " \ - "cgalPkgDemo{4}=Windows Demos: \1, \3
    Common Demo Dlls: dlls
    " \ - "cgalPkgDemo{6}=Windows Demos: \1, \3, \5
    Common Demo Dlls: dlls
    " \ + "cgalPkgDemo{2}=Windows demo: \1
    Common demo dlls: dlls
    " \ + "cgalPkgDemo{4}=Windows demos: \1, \3
    Common demo dlls: dlls
    " \ + "cgalPkgDemo{6}=Windows demos: \1, \3, \5
    Common demo dlls: dlls
    " \ "cgalPkgDescriptionEnd=" \ "cgalModifBegin=\htmlonly
    \endhtmlonly \xrefitem Modification \"Modifications\" \"MODIFICATIONS\"" \ "cgalModifEnd=\htmlonly
    \endhtmlonly \latexonly END MODIFICATIONS \endlatexonly" \ @@ -197,7 +197,9 @@ ALIASES = "cgal=%CGAL" \ "cgalParamNEnd= \htmlonly[block] \endhtmlonly " \ "cgalParamSectionBegin{1}=\cgalParamNBegin{\1}" \ "cgalParamSectionEnd=\cgalParamNEnd" \ - "cgalParamPrecondition{1}=
  • Precondition: \1
  • " + "cgalParamPrecondition{1}=
  • Precondition: \1
  • " \ + "cgalBigO{1}=\f$O(\1)\f$" \ + "cgalBigOLarge{1}=\f$O\left(\1\right)\f$" # Doxygen selects the parser to use depending on the extension of the files it # parses. With this tag you can assign which parser to use for a given @@ -791,5 +793,5 @@ GENERATE_LEGEND = NO # NO_ADDITIONAL_DETAILS tag is set to YES. This tag has no effect if # the EXTRACT_ALL tag is set to NO. # The default value is: NO. -NO_ADDITIONAL_DETAILS = YES +${CGAL_OPT_NO_ADDITIONAL_DETAILS} diff --git a/Documentation/doc/resources/1.9.6/menu_version.js b/Documentation/doc/resources/1.9.6/menu_version.js index a66903b10fe..f3b20c2fe00 100644 --- a/Documentation/doc/resources/1.9.6/menu_version.js +++ b/Documentation/doc/resources/1.9.6/menu_version.js @@ -6,7 +6,8 @@ var current_version_local = 'master' var all_versions = [ 'master', - '5.6-beta1', + '6.0-beta1', + '5.6', 'latest', '5.5.2', '5.4.4', diff --git a/Envelope_3/include/CGAL/Envelope_3/Envelope_diagram_on_surface_2.h b/Envelope_3/include/CGAL/Envelope_3/Envelope_diagram_on_surface_2.h index c8aa90f709b..b9f922ef699 100644 --- a/Envelope_3/include/CGAL/Envelope_3/Envelope_diagram_on_surface_2.h +++ b/Envelope_3/include/CGAL/Envelope_3/Envelope_diagram_on_surface_2.h @@ -129,14 +129,14 @@ public: template class is_arrangement_2< Envelope_diagram_on_surface_2 -> : public boost::true_type +> : public std::true_type {}; // specialization template class is_arrangement_2< Envelope_diagram_2 -> : public boost::true_type +> : public std::true_type {}; diff --git a/Filtered_kernel/include/CGAL/Filtered_kernel.h b/Filtered_kernel/include/CGAL/Filtered_kernel.h index 182ba3c4d99..3a41cabf3f0 100644 --- a/Filtered_kernel/include/CGAL/Filtered_kernel.h +++ b/Filtered_kernel/include/CGAL/Filtered_kernel.h @@ -21,10 +21,6 @@ #include #include -#include -#include -#include - #include #include diff --git a/Filtered_kernel/include/CGAL/Lazy.h b/Filtered_kernel/include/CGAL/Lazy.h index e7024f6220b..43d6a5ddc11 100644 --- a/Filtered_kernel/include/CGAL/Lazy.h +++ b/Filtered_kernel/include/CGAL/Lazy.h @@ -2088,10 +2088,10 @@ struct Lazy_construction { typedef typename LK::Approximate_kernel AK; typedef typename LK::Exact_kernel EK; - typedef typename boost::remove_cv< - typename boost::remove_reference < typename AC::result_type >::type >::type AT; - typedef typename boost::remove_cv< - typename boost::remove_reference < typename EC::result_type >::type >::type ET; + typedef std::remove_cv_t< + std::remove_reference_t < typename AC::result_type > > AT; + typedef std::remove_cv_t< + std::remove_reference_t < typename EC::result_type > > ET; typedef typename Default::Get::type E2A; diff --git a/Filtered_kernel/include/CGAL/Lazy_kernel.h b/Filtered_kernel/include/CGAL/Lazy_kernel.h index 08a6ebb41a0..702ded2525d 100644 --- a/Filtered_kernel/include/CGAL/Lazy_kernel.h +++ b/Filtered_kernel/include/CGAL/Lazy_kernel.h @@ -29,8 +29,7 @@ #include #include #include -#include -#include +#include #if defined(BOOST_MSVC) # pragma warning(push) @@ -63,8 +62,8 @@ public: template struct Has_result_type - : boost::integral_constant< bool, - Has_result_type_helper< typename boost::remove_cv::type>::value> + : std::integral_constant< bool, + Has_result_type_helper< std::remove_cv_t>::value> {}; template @@ -191,10 +190,10 @@ private: template struct Lazy_wrapper_traits : boost::mpl::eval_if< internal::Has_result_type, - boost::mpl::eval_if< std::is_same< typename boost::remove_cv< - typename boost::remove_reference< + boost::mpl::eval_if< std::is_same< std::remove_cv_t< + std::remove_reference_t< typename internal::Lazy_result_type::type - >::type >::type, + > >, typename Approximate_kernel::FT>, boost::mpl::int_, boost::mpl::eval_if< std::is_same< typename internal::Lazy_result_type::type, diff --git a/Generalized_map/doc/Generalized_map/Generalized_map.txt b/Generalized_map/doc/Generalized_map/Generalized_map.txt index 491a8c9ed3d..ec178eb6dc1 100644 --- a/Generalized_map/doc/Generalized_map/Generalized_map.txt +++ b/Generalized_map/doc/Generalized_map/Generalized_map.txt @@ -296,7 +296,7 @@ Several functions allow to create specific configurations of darts into a genera \subsection ssecadvmarksgmap Boolean Marks -It is often necessary to mark darts, for example to retrieve in O(1) if a given dart was already processed during a specific algorithm, for example, iteration over a given range. Users can also mark specific parts of a generalized map (for example mark all the darts belonging to objects having specific semantics). To answer these needs, a `GeneralizedMap` has a certain number of Boolean marks (fixed by the constant \link GenericMap::NB_MARKS `NB_MARKS`\endlink). When one wants to use a Boolean mark, the following methods are available (with `gm` an instance of a generalized map): +It is often necessary to mark darts, for example to retrieve in \cgalBigO{1} if a given dart was already processed during a specific algorithm, for example, iteration over a given range. Users can also mark specific parts of a generalized map (for example mark all the darts belonging to objects having specific semantics). To answer these needs, a `GeneralizedMap` has a certain number of Boolean marks (fixed by the constant \link GenericMap::NB_MARKS `NB_MARKS`\endlink). When one wants to use a Boolean mark, the following methods are available (with `gm` an instance of a generalized map): diff --git a/Triangulation_on_sphere_2/include/CGAL/Delaunay_triangulation_on_sphere_2.h b/Triangulation_on_sphere_2/include/CGAL/Delaunay_triangulation_on_sphere_2.h index b235ad31d47..c6751c2a3cb 100644 --- a/Triangulation_on_sphere_2/include/CGAL/Delaunay_triangulation_on_sphere_2.h +++ b/Triangulation_on_sphere_2/include/CGAL/Delaunay_triangulation_on_sphere_2.h @@ -631,8 +631,8 @@ insert(InputIterator first, InputIterator beyond, { typedef Point_3_with_iterator P3_wit; - CGAL_static_assertion((std::is_same::value_type, Point>::value)); - CGAL_static_assertion(!(std::is_same::value)); + static_assert(std::is_same::value_type, Point>::value); + static_assert(!std::is_same::value); const size_type n = number_of_vertices(); diff --git a/Triangulation_on_sphere_2/include/CGAL/Triangulation_on_sphere_2/internal/arc_on_sphere_2_subsampling.h b/Triangulation_on_sphere_2/include/CGAL/Triangulation_on_sphere_2/internal/arc_on_sphere_2_subsampling.h index fbe52979939..98dc2f54c65 100644 --- a/Triangulation_on_sphere_2/include/CGAL/Triangulation_on_sphere_2/internal/arc_on_sphere_2_subsampling.h +++ b/Triangulation_on_sphere_2/include/CGAL/Triangulation_on_sphere_2/internal/arc_on_sphere_2_subsampling.h @@ -56,7 +56,7 @@ double get_theta(typename Kernel::Point_3& pt, #endif >::type Col; - CGAL_static_assertion_msg(!(std::is_same::value), + static_assert(!(std::is_same::value), "Eigen is required to perform arc subsampling!"); auto V1c = V1.cartesian_begin(), V2c = V2.cartesian_begin(), V3c = V3.cartesian_begin(); diff --git a/Visibility_2/doc/Visibility_2/CGAL/Rotational_sweep_visibility_2.h b/Visibility_2/doc/Visibility_2/CGAL/Rotational_sweep_visibility_2.h index 3ad8ae61144..fcaf29e1a7c 100644 --- a/Visibility_2/doc/Visibility_2/CGAL/Rotational_sweep_visibility_2.h +++ b/Visibility_2/doc/Visibility_2/CGAL/Rotational_sweep_visibility_2.h @@ -5,7 +5,7 @@ namespace CGAL { \brief This class is a model of the concept `Visibility_2` can answer visibility queries within a polygon that may have holes. -\details The algorithm does not require preprocessing. It relies on the algorithm of T. Asano \cite ta-aeafvpprh-85 based on angular plane sweep, with a time complexity of \f$O (n \log n)\f$ in the number of vertices. +\details The algorithm does not require preprocessing. It relies on the algorithm of T. Asano \cite ta-aeafvpprh-85 based on angular plane sweep, with a time complexity of \cgalBigO{n \log n} in the number of vertices. \tparam Arrangement_2_ is the type used to represent the input environment. @@ -63,7 +63,7 @@ public: /*! Attaches the given arrangement to the visibility object. -This operation takes \f$O(1)\f$ as the class does no pre-processing. +This operation takes \cgalBigO{1} as the class does no pre-processing. In case the object is already attached to another arrangement, the visibility object gets detached before being attached to `arr`. diff --git a/Visibility_2/doc/Visibility_2/CGAL/Simple_polygon_visibility_2.h b/Visibility_2/doc/Visibility_2/CGAL/Simple_polygon_visibility_2.h index f073ea8cc24..daa988c11b2 100644 --- a/Visibility_2/doc/Visibility_2/CGAL/Simple_polygon_visibility_2.h +++ b/Visibility_2/doc/Visibility_2/CGAL/Simple_polygon_visibility_2.h @@ -12,7 +12,7 @@ It computes the visibility region from a viewpoint that is in the interior or on While scanning the boundary the algorithm uses a stack to manipulate the vertices, and ultimately yields the visibility region. For each scanned edge, at most 2 points are pushed onto the stack. Overall, at most 2\f$ n \f$ points are pushed or popped. Thus, the time and space complexities of the -algorithm are \f$ O(n) \f$ even in case of degeneracies such as needles, where \f$ n \f$ +algorithm are \cgalBigO{n}$ even in case of degeneracies such as needles, where \f$ n \f$ is the number of the vertices of the polygon. \tparam Arrangement_2_ is the type used to represent the input environment. @@ -67,7 +67,7 @@ public: /*! Attaches the given arrangement to the visibility object. -This operation takes \f$O(1)\f$ as the class does no pre-processing. +This operation takes \cgalBigO{1} as the class does no pre-processing. In case the object is already attached to another arrangement, the visibility object gets detached before being attached to `arr`. diff --git a/Visibility_2/doc/Visibility_2/CGAL/Triangular_expansion_visibility_2.h b/Visibility_2/doc/Visibility_2/CGAL/Triangular_expansion_visibility_2.h index 178a812957d..6606de87dfa 100644 --- a/Visibility_2/doc/Visibility_2/CGAL/Triangular_expansion_visibility_2.h +++ b/Visibility_2/doc/Visibility_2/CGAL/Triangular_expansion_visibility_2.h @@ -6,8 +6,8 @@ namespace CGAL { \details The algorithm obtains a constrained triangulation from the input arrangement, then computes visibility by expanding the triangle that contains the query point. -Preprocessing takes \f$ O(n)\f$ time and \f$ O(n) \f$ space, where \f$ n \f$ is the number of vertices of input polygon. -The query time is \f$ O(nh)\f$, where \f$ h \f$ is the number of holes+1 of input polygon. Thus, for simple polygons (or a polygon with a constant number of holes) the algorithm complexity is linear, but it is \f$ O(n^2)\f$ in the worst case, as the number of holes can be linear in \f$ n \f$. +Preprocessing takes \cgalBigO{n} time and \cgalBigO{n}$ space, where \f$ n \f$ is the number of vertices of input polygon. +The query time is \cgalBigO{nh}, where \f$ h \f$ is the number of holes+1 of input polygon. Thus, for simple polygons (or a polygon with a constant number of holes) the algorithm complexity is linear, but it is \cgalBigO{n^2} in the worst case, as the number of holes can be linear in \f$ n \f$. \tparam Arrangement_2_ is the type used to represent the input environment. @@ -63,7 +63,7 @@ public: /*! Attaches the given arrangement to the visibility object and computes the restricted triangulation. -This takes \f$ O(n) \f$ time, where \f$ n \f$ is the number of vertices. +This takes \cgalBigO{n}$ time, where \f$ n \f$ is the number of vertices. From this moment on the class observes changes in the arrangement. If the arrangement changes a new restricted triangulation is computed. Re-attaching forces re-computation. diff --git a/Visibility_2/doc/Visibility_2/visibility_2.txt b/Visibility_2/doc/Visibility_2/visibility_2.txt index 891d813009f..d0dcdc09c49 100644 --- a/Visibility_2/doc/Visibility_2/visibility_2.txt +++ b/Visibility_2/doc/Visibility_2/visibility_2.txt @@ -74,9 +74,9 @@ The following models of the `Visibility_2` concept are provided:
    Class | Function | Preprocessing | Query |Algorithm -------------------------------|-----------------------------------------------------|-------------------------------|-----------------------------------|------------------------------- - `Simple_polygon_visibility_2` | simple polygons | No |\f$ O(n) \f$ time and \f$ O(n) \f$ space | B. Joe and R. B. Simpson \cite bjrb-clvpa-87 - `Rotational_sweep_visibility_2` | polygons with holes | No | \f$ O(n\log n) \f$ time and \f$ O(n) \f$ space | T. Asano \cite ta-aeafvpprh-85 -`Triangular_expansion_visibility_2` | polygons with holes | \f$ O(n) \f$ time and \f$ O(n) \f$ space | \f$ O(nh) \f$ time and \f$ O(n) \f$ space. | Bungiu et al. \cite ecvp-bhhhk-14 + `Simple_polygon_visibility_2` | simple polygons | No |\cgalBigO{n}$ time and \cgalBigO{n}$ space | B. Joe and R. B. Simpson \cite bjrb-clvpa-87 + `Rotational_sweep_visibility_2` | polygons with holes | No | \cgalBigO{n\log n}$ time and \cgalBigO{n}$ space | T. Asano \cite ta-aeafvpprh-85 +`Triangular_expansion_visibility_2` | polygons with holes | \cgalBigO{n}$ time and \cgalBigO{n}$ space | \cgalBigO{nh}$ time and \cgalBigO{n}$ space. | Bungiu et al. \cite ecvp-bhhhk-14
    Where \f$ n \f$ denotes the number of vertices of \f$ f \f$ and \f$ h \f$ the number of holes+1. @@ -158,4 +158,4 @@ During Google Summer of Code 2014 Ning Xu fixed a bug in `CGAL::Simple_polygon_v } -// `Preprocessed_rotational_sweep_visibility_2` | polygons with holes | \f$ O(n^2) \f$ time and \f$ O(n^2) \f$ space | \f$ O(n) \f$ time and \f$ O(n) \f$ space | Takao Asano, Tetsuo Asano etc \cite aaghi-vpsesp-85 +// `Preprocessed_rotational_sweep_visibility_2` | polygons with holes | \cgalBigO{n^2}$ time and \cgalBigO{n^2}$ space | \cgalBigO{n}$ time and \cgalBigO{n}$ space | Takao Asano, Tetsuo Asano etc \cite aaghi-vpsesp-85 diff --git a/ccpp.yml b/ccpp.yml deleted file mode 100644 index 75bbbee4918..00000000000 --- a/ccpp.yml +++ /dev/null @@ -1,12 +0,0 @@ -name: C/C++ CI - -on: [push] - -jobs: - build: - - runs-on: ubuntu-latest - - steps: - - name: configure all - run: cmake -DWITH_examples=ON -DWITH_tests=ON -DWITH_demos=ON .