From 71cbe1cf50d6d93d298b6d2744aa06848cb1d036 Mon Sep 17 00:00:00 2001 From: Dave Abrahams Date: Fri, 1 Mar 2002 21:24:49 +0000 Subject: [PATCH] quick fixes for KCC [SVN r13000] --- .../python/converter/from_python_data.hpp | 22 +++++++++++-------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/include/boost/python/converter/from_python_data.hpp b/include/boost/python/converter/from_python_data.hpp index fe026172..9b418957 100644 --- a/include/boost/python/converter/from_python_data.hpp +++ b/include/boost/python/converter/from_python_data.hpp @@ -15,7 +15,7 @@ # include # include # include -//# include +# include # include # include # include @@ -129,19 +129,23 @@ namespace detail BOOST_STATIC_CONSTANT(std::size_t, target = referent_alignment::value); typedef lower_alignment t1; + + BOOST_STATIC_CONSTANT(bool, t1_aligned = + (alignment_of::value >= target) + & (alignment_of::value % target == 0)); + typedef lower_size::value> t2; + BOOST_STATIC_CONSTANT(bool, t2_aligned = + (alignment_of::value >= target) + & (alignment_of::value % target == 0)); + + typedef typename mpl::select_type< - ::boost::detail::ice_and< - alignment_of::value >= target - , alignment_of::value % target == 0 - >::value + t1_aligned , t1 , typename mpl::select_type< - ::boost::detail::ice_and< - alignment_of::value >= target - , alignment_of::value % target == 0 - >::value + t2_aligned , t2 , max_align >::type