`BOOST_HAS_VARIADIC_TMPL` and `BOOST_NO_CXX11_VARIADIC_TEMPLATES` can be
wrong, with Boost-1.57 and gcc>=5.0.
Fixes the following warnings with gcc>=5.0 in C++98 mode:
> CGAL-4.8-Ic-106/include/CGAL/array.h:78:31: warning: variadic templates only available with -std=c++11 or -std=gnu++11
> template< typename T, typename... Args >
> ^
> CGAL-4.8-Ic-106/include/CGAL/array.h:80:28: warning: variadic templates only available with -std=c++11 or -std=gnu++11
> cpp11::array< T, 1 + sizeof...(Args) >
> ^
> CGAL-4.8-Ic-106/include/CGAL/array.h:81:42: warning: variadic templates only available with -std=c++11 or -std=gnu++11
> make_array(const T & t, const Args & ... args)
> ^
- Change the way the macros `CGAL_CAN_USE_CXX11_THREAD_LOCAL` and
`CGAL_CAN_USE_CXX11_MUTEX` are defined, so that other compilers are
also supported.
- Add the macro `CGAL_CAN_USE_CXX11_ATOMIC` and the header
`<CGAL/atomic.h>`.
The deprecated names may be removed from future versions of Boost, and
we do not want our C++11 support be dropped for users using newest
versions of Boost.
This macro is always defined. Its value will be true when assertions are defined
and false when assertions are not defined. This macro can then be used in place
of a true false constant, such as is needed for CGAL_NOEXCEPT.
This macro is available for future compatibility with c++11, which
by default marks destructors noexcept(true). Some destructors
in CGAL do throw exceptions an so should be marked noexcept(false).
Since noexcept is not available in c++0x and below the macro is
disabled when CGAL_CXX11 is not defined since it is not required.
This macro has to be larger than the default value
and it must be set before including <boost/parameter.hpp>
Instead of setting it to 12 in the packages that
need it, we do this in <CGAL/config.h> and produce
an error if a user has set it to a value < 12
somehow, boost/random.hpp includes boost/type_traits/has_binary_operator.hpp,
and the "parse error" happens in this file (as said in the bug report)
Also update the link to the official Qt bug report
Introduces a redesign of the CGAL extension of the BGL API
Successfully tested in CGAL-4.5-Ic-90
Approved by the Release Manager
Conflicts:
Surface_mesh_segmentation/test/Surface_mesh_segmentation/test_compute_sdf_values_and_segment_exact_rational.cpp
A warning of clang showed me my mistake:
In file included from /no-raid/home/lrineau/CGAL/CGAL-4.4-I-10/cmake/platforms/x86-64_Linux-Fedora18_llvm-clang-with-g++-4.7/test/Kinetic_data_structures/timings.cpp:14:
In file included from /no-raid/home/lrineau/CGAL/CGAL-4.4-I-10/include/CGAL/Kinetic/Delaunay_triangulation_3.h:32:
In file included from /no-raid/home/lrineau/CGAL/CGAL-4.4-I-10/include/CGAL/Delaunay_triangulation_3.h:31:
In file included from /no-raid/home/lrineau/CGAL/CGAL-4.4-I-10/include/CGAL/Triangulation_3.h:37:
/no-raid/home/lrineau/CGAL/CGAL-4.4-I-10/include/CGAL/Triangulation_data_structure_3.h:938:7: warning: logical not is only applied to the left hand side of this comparison [-Wlogical-not-parentheses]
CGAL_assume(index_v_in_n0 <= 1);
^ ~~
/no-raid/home/lrineau/CGAL/CGAL-4.4-I-10/include/CGAL/assertions.h:86:29: note: expanded from macro 'CGAL_assume'
# define CGAL_assume(EX) CGAL_ASSUME(EX)
^
/no-raid/home/lrineau/CGAL/CGAL-4.4-I-10/include/CGAL/config.h:334:30: note: expanded from macro 'CGAL_ASSUME'
# define CGAL_ASSUME(EX) if(!EX) { __builtin_unreachable(); }
^
Trivial bug-fix.
CGAL_assume(EX) is like CGAL_assertion, but is not disabled in release
mode. In debug mode, it is similar to CGAL_assertion(). In release mode, it
uses builtins of the compilateur, like the MSVC __assume or the g++/clang
__builtin_unreachable to give an hint to the compiler that some situation
in the code cannot happen.