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 7304ae08b48..2e5ec298880 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 @@ -200,50 +200,8 @@ public: // alias template. This feature can be mimiked by non C++11 support simply by // defining a type that inherits from the template we need to alias. However, // the non-C++11 code requires the (re)definition of all constructors of the - // derived class. The non-C++11 code follows the commented out C++11 code. - // When we move to C++11 we can use the more elgant code. -#if 0 - // Type definition for the construction surface-sweep visitor. - template - using Construction_helper = - Arr_bounded_planar_construction_helper; - - // Type definition for the no-intersection construction surface-sweep visitor. - template - using No_intersection_construction_helper = - Arr_bounded_planar_construction_helper; - - // Type definition for the insertion surface-sweep visitor. - typedef Arr_insertion_traits_2 I_traits; - template - using Insertion_helper = - Arr_bounded_planar_insertion_helper; - - // Type definition for the no-intersection insertion surface-sweep visitor. - typedef Arr_basic_insertion_traits_2 Nxi_traits; - template - using No_intersection_insertion_helper = - Arr_bounded_planar_insertion_helper; - - // Type definition for the batched point-location surface-sweep visitor. - typedef Arr_batched_point_location_traits_2 Bpl_traits; - template - using Batched_point_location_helper = - Arr_bounded_planar_batched_pl_helper; - - // Type definition for the vertical decomposition sweep-line visitor. - typedef Arr_batched_point_location_traits_2 Vd_traits; - template - using Vertical_decomposition_helper = - Arr_bounded_planar_vert_decomp_helper; - - // Type definition for the overlay surface-sweep visitor. - template - using Overlay_helper = - Arr_bounded_planar_overlay_helper; - -#else + // derived class. +#if defined(CGAL_CFG_NO_CPP0X_TEMPLATE_ALIASES) // Type definition for the construction surface-sweep visitor. template struct Construction_helper : @@ -318,6 +276,46 @@ public: Base; Overlay_helper(const ArrA* arr_a, const ArrB* arr_b) : Base(arr_a, arr_b) {} }; +#else + // Type definition for the construction surface-sweep visitor. + template + using Construction_helper = + Arr_bounded_planar_construction_helper; + + // Type definition for the no-intersection construction surface-sweep visitor. + template + using No_intersection_construction_helper = + Arr_bounded_planar_construction_helper; + + // Type definition for the insertion surface-sweep visitor. + typedef Arr_insertion_traits_2 I_traits; + template + using Insertion_helper = + Arr_bounded_planar_insertion_helper; + + // Type definition for the no-intersection insertion surface-sweep visitor. + typedef Arr_basic_insertion_traits_2 Nxi_traits; + template + using No_intersection_insertion_helper = + Arr_bounded_planar_insertion_helper; + + // Type definition for the batched point-location surface-sweep visitor. + typedef Arr_batched_point_location_traits_2 Bpl_traits; + template + using Batched_point_location_helper = + Arr_bounded_planar_batched_pl_helper; + + // Type definition for the vertical decomposition sweep-line visitor. + typedef Arr_batched_point_location_traits_2 Vd_traits; + template + using Vertical_decomposition_helper = + Arr_bounded_planar_vert_decomp_helper; + + // Type definition for the overlay surface-sweep visitor. + template + using Overlay_helper = + Arr_bounded_planar_overlay_helper; #endif //@} 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 a7327d4242d..b890a14de96 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 @@ -315,49 +315,7 @@ public: // the non-C++11 code requires the (re)definition of all constructors of the // derived class. The non-C++11 code follows the commented out C++11 code. // When we move to C++11 we can use the more elgant code. -#if 0 - // Type definition for the construction surface-sweep visitor. - template - using Construction_helper = - Arr_spherical_construction_helper; - - // Type definition for the no-intersection construction surface-sweep visitor. - template - using No_intersection_construction_helper = - Arr_spherical_construction_helper; - - // Type definition for the insertion surface-sweep visitor. - typedef Arr_insertion_traits_2 I_traits; - template - using Insertion_helper = - Arr_spherical_insertion_helper; - - // Type definition for the no-intersection insertion surface-sweep visitor. - typedef Arr_basic_insertion_traits_2 Nxi_traits; - template - using No_intersection_insertion_helper = - Arr_spherical_insertion_helper; - - // Type definition for the batched point-location surface-sweep visitor. - typedef Arr_batched_point_location_traits_2 Bpl_traits; - template - using Batched_point_location_helper = - Arr_spherical_batched_pl_helper; - - // Type definition for the vertical decomposition surface-sweep visitor. - typedef Arr_batched_point_location_traits_2 Vd_traits; - template - using Vertical_decomposition_helper = - Arr_spherical_vert_decomp_helper; - - // Type definition for the overlay surface-sweep visitor. - template - using Overlay_helper = - Arr_spherical_overlay_helper; - -#else - +#if defined(CGAL_CFG_NO_CPP0X_TEMPLATE_ALIASES) // Type definition for the construction surface-sweep visitor. template struct Construction_helper : @@ -432,7 +390,46 @@ public: Base; Overlay_helper(const ArrA* arr_a, const ArrB* arr_b) : Base(arr_a, arr_b) {} }; +#else + // Type definition for the construction surface-sweep visitor. + template + using Construction_helper = + Arr_spherical_construction_helper; + // Type definition for the no-intersection construction surface-sweep visitor. + template + using No_intersection_construction_helper = + Arr_spherical_construction_helper; + + // Type definition for the insertion surface-sweep visitor. + typedef Arr_insertion_traits_2 I_traits; + template + using Insertion_helper = + Arr_spherical_insertion_helper; + + // Type definition for the no-intersection insertion surface-sweep visitor. + typedef Arr_basic_insertion_traits_2 Nxi_traits; + template + using No_intersection_insertion_helper = + Arr_spherical_insertion_helper; + + // Type definition for the batched point-location surface-sweep visitor. + typedef Arr_batched_point_location_traits_2 Bpl_traits; + template + using Batched_point_location_helper = + Arr_spherical_batched_pl_helper; + + // Type definition for the vertical decomposition surface-sweep visitor. + typedef Arr_batched_point_location_traits_2 Vd_traits; + template + using Vertical_decomposition_helper = + Arr_spherical_vert_decomp_helper; + + // Type definition for the overlay surface-sweep visitor. + template + using Overlay_helper = + Arr_spherical_overlay_helper; #endif //@} 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 1aed5bc7f5a..4931931a80b 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 @@ -218,49 +218,8 @@ public: // alias template. This feature can be mimiked by non C++11 support simply by // defining a type that inherits from the template we need to alias. However, // the non-C++11 code requires the (re)definition of all constructors of the - // derived class. The non-C++11 code follows the commented out C++11 code. - // When we move to C++11 we can use the more elgant code. -#if 0 - // Type definition for the construction surface-sweep visitor. - template - using Construction_helper = - Arr_unb_planar_construction_helper; - - // Type definition for the no-intersection construction surface-sweep visitor. - template - using No_intersection_construction_helper = - Arr_unb_planar_construction_helper; - - // Type definition for the insertion surface-sweep visitor. - typedef Arr_insertion_traits_2 I_traits; - template - using Insertion_helper = - Arr_unb_planar_insertion_helper; - - // Type definition for the no-intersection insertion surface-sweep visitor. - typedef Arr_basic_insertion_traits_2 Nxi_traits; - template - using No_intersection_insertion_helper = - Arr_unb_planar_insertion_helper; - - // Type definition for the batched point-location surface-sweep visitor. - typedef Arr_batched_point_location_traits_2 Bpl_traits; - template - using Batched_point_location_helper = - Arr_unb_planar_batched_pl_helper; - - // Type definition for the vertical decomposition surface-sweep visitor. - typedef Arr_batched_point_location_traits_2 Vd_traits; - template - using Vertical_decomposition_helper = - Arr_unb_planar_vert_decomp_helper; - - // Type definition for the overlay surface-sweep visitor. - template - using Overlay_helper = - Arr_unb_planar_overlay_helper; -#else + // derived class. +#if defined(CGAL_CFG_NO_CPP0X_TEMPLATE_ALIASES) // Type definition for the construction surface-sweep visitor. template struct Construction_helper : @@ -335,6 +294,46 @@ public: Base; Overlay_helper(const ArrA* arr_a, const ArrB* arr_b) : Base(arr_a, arr_b) {} }; +#else + // Type definition for the construction surface-sweep visitor. + template + using Construction_helper = + Arr_unb_planar_construction_helper; + + // Type definition for the no-intersection construction surface-sweep visitor. + template + using No_intersection_construction_helper = + Arr_unb_planar_construction_helper; + + // Type definition for the insertion surface-sweep visitor. + typedef Arr_insertion_traits_2 I_traits; + template + using Insertion_helper = + Arr_unb_planar_insertion_helper; + + // Type definition for the no-intersection insertion surface-sweep visitor. + typedef Arr_basic_insertion_traits_2 Nxi_traits; + template + using No_intersection_insertion_helper = + Arr_unb_planar_insertion_helper; + + // Type definition for the batched point-location surface-sweep visitor. + typedef Arr_batched_point_location_traits_2 Bpl_traits; + template + using Batched_point_location_helper = + Arr_unb_planar_batched_pl_helper; + + // Type definition for the vertical decomposition surface-sweep visitor. + typedef Arr_batched_point_location_traits_2 Vd_traits; + template + using Vertical_decomposition_helper = + Arr_unb_planar_vert_decomp_helper; + + // Type definition for the overlay surface-sweep visitor. + template + using Overlay_helper = + Arr_unb_planar_overlay_helper; #endif //@} diff --git a/Installation/include/CGAL/config.h b/Installation/include/CGAL/config.h index 39650cf5b13..e9eaac53cf9 100644 --- a/Installation/include/CGAL/config.h +++ b/Installation/include/CGAL/config.h @@ -3,7 +3,7 @@ // ETH Zurich (Switzerland), // INRIA Sophia-Antipolis (France), // Max-Planck-Institute Saarbruecken (Germany), -// and Tel-Aviv University (Israel). All rights reserved. +// and Tel-Aviv University (Israel). All rights reserved. // // This file is part of CGAL (www.cgal.org); you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public License as @@ -18,9 +18,9 @@ // // $URL$ // $Id$ -// // -// Author(s) : Wieger Wesselink +// +// Author(s) : Wieger Wesselink // Michael Hoffmann // Sylvain Pion // Laurent Rineau @@ -105,7 +105,7 @@ # define BOOST_TT_HAS_POST_INCREMENT_HPP_INCLUDED #endif -// The following header file defines among other things BOOST_PREVENT_MACRO_SUBSTITUTION +// The following header file defines among other things BOOST_PREVENT_MACRO_SUBSTITUTION #include #include @@ -223,6 +223,10 @@ || (BOOST_VERSION < 103600) #define CGAL_CFG_NO_CPP0X_EXPLICIT_CONVERSION_OPERATORS 1 #endif +#if defined(BOOST_NO_CXX11_TEMPLATE_ALIASES) || \ + defined(BOOST_NO_TEMPLATE_ALIASES) || (BOOST_VERSION < 103900) +#define CGAL_CFG_NO_CPP0X_TEMPLATE_ALIASES 1 +#endif // Some random list to let us write C++11 without thinking about // each feature we are using. @@ -262,7 +266,7 @@ #define CGAL_VERSION_NUMBER(x,y,z) (1000001 + 10000*x + 100*y + 10*z) * 1000 #ifndef CGAL_NO_DEPRECATED_CODE -#define CGAL_BEGIN_NAMESPACE namespace CGAL { +#define CGAL_BEGIN_NAMESPACE namespace CGAL { #define CGAL_END_NAMESPACE } #endif @@ -374,10 +378,10 @@ #endif //-------------------------------------------------------------------// -// When the global min and max are no longer defined (as macros) -// because of NOMINMAX flag definition, we define our own global +// When the global min and max are no longer defined (as macros) +// because of NOMINMAX flag definition, we define our own global // min/max functions to make the Microsoft headers compile. (afxtempl.h) -// Users that does not want the global min/max +// Users that does not want the global min/max // should define CGAL_NOMINMAX //-------------------------------------------------------------------// #include @@ -399,7 +403,7 @@ using std::max; # define CGAL_PRETTY_FUNCTION __FUNCSIG__ #elif defined __GNUG__ # define CGAL_PRETTY_FUNCTION __PRETTY_FUNCTION__ -#else +#else # define CGAL_PRETTY_FUNCTION __func__ // with sunpro, this requires -features=extensions #endif