Patch for compiler gcc4.3

(Sebastien is the best, even it is not fair because I don't have access to the compiler. But I will pay my beer ;)
This commit is contained in:
Guillaume Damiand 2013-06-13 14:53:04 +02:00
parent 67756fd5d3
commit 50fd54b5f1
1 changed files with 5 additions and 19 deletions

View File

@ -25,6 +25,7 @@
#include <CGAL/Dimension.h> #include <CGAL/Dimension.h>
#include <CGAL/Kernel_traits.h> #include <CGAL/Kernel_traits.h>
#include <vector> #include <vector>
#include <boost/mpl/has_xxx.hpp>
/* Definition of functors used internally to manage attributes (we need /* Definition of functors used internally to manage attributes (we need
* functors as attributes are stored in tuple, thus all the access must be * functors as attributes are stored in tuple, thus all the access must be
@ -611,13 +612,7 @@ struct Is_same_attribute_point_functor<Map1, Map2, T1, T2, false, false, i>
{ return true; } { return true; }
}; };
// **************************************************************************** // ****************************************************************************
struct twochar{ char dummy[2]; }; BOOST_MPL_HAS_XXX_TRAIT_NAMED_DEF(Has_point,Point,false)
template<typename T>
static char has_point(typename T::Point*);
template<typename T>
static twochar has_point(...);
template<typename Attr, typename Info=typename Attr::Info> template<typename Attr, typename Info=typename Attr::Info>
struct Is_nonvoid_attribute_has_non_void_info struct Is_nonvoid_attribute_has_non_void_info
@ -640,19 +635,10 @@ struct Is_attribute_has_non_void_info<CGAL::Void>
{ {
static const bool value=false; static const bool value=false;
}; };
// ****************************************************************************
template<typename Attr, bool withpoint=
sizeof(has_point<Attr>(NULL))==sizeof(char)>
struct Is_attribute_has_point
{
static const bool value=true;
};
template<typename Attr> template<typename Attr>
struct Is_attribute_has_point<Attr, false> struct Is_attribute_has_point
{ { static const bool value=Has_point<Attr>::value; };
static const bool value=false;
};
// **************************************************************************** // ****************************************************************************
/// Test if the two darts are associated with the same attribute. /// Test if the two darts are associated with the same attribute.
template<typename Map1, typename Map2> template<typename Map1, typename Map2>