[LLVMbugs] [Bug 12727] New: Failure to compile Boost.Python

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Wed May 2 09:40:59 PDT 2012


http://llvm.org/bugs/show_bug.cgi?id=12727

             Bug #: 12727
           Summary: Failure to compile Boost.Python
           Product: clang
           Version: trunk
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: luc_j_bourhis at mac.com
                CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
    Classification: Unclassified


clang++ fails to compile the preprocessed source available here (too big to
attach, hence that link):
http://80.11.252.214/~luc/wrapper.cpp

In case it helps, I bisected Boost to find the Boost commit which broke it (as
I discovered that problem by updating my Boost repository): it is rev 77146,

Author: johnmaddock <johnmaddock at b8fc166d-592f-0410-95f2-cb63ce0dd405>
Date:   Thu Mar 1 11:27:18 2012 +0000

    Apply Clang patch from Michel Morin.

and its diff is as follow

diff --git a/boost/type_traits/intrinsics.hpp
b/boost/type_traits/intrinsics.hpp
index d47b33e..e5c25d3 100644
--- a/boost/type_traits/intrinsics.hpp
+++ b/boost/type_traits/intrinsics.hpp
@@ -131,10 +131,10 @@
 #   if __has_feature(is_union)
 #     define BOOST_IS_UNION(T) __is_union(T)
 #   endif
-#   if __has_feature(is_pod) && defined(_LIBCPP_VERSION)
+#   if (__has_feature(is_pod) && defined(_LIBCPP_VERSION)) ||
__has_feature(__is_pod__)
 #     define BOOST_IS_POD(T) __is_pod(T)
 #   endif
-#   if __has_feature(is_empty) && defined(_LIBCPP_VERSION)
+#   if (__has_feature(is_empty) && defined(_LIBCPP_VERSION)) ||
__has_feature(__is_empty__)
 #     define BOOST_IS_EMPTY(T) __is_empty(T)
 #   endif
 #   if __has_feature(has_trivial_constructor)


Finally, here are the errors reported by clang++

~> clang++ -c wrapper.cpp
In file included from
/Users/luc/Developer/cctbx/boost/libs/python/src/wrapper.cpp:1:
In file included from
/Users/luc/Developer/cctbx/boost/libs/python/src/wrapper.cpp:5:
In file included from
/Users/luc/Developer/cctbx/boost/boost/python/wrapper.hpp:8:
In file included from
/Users/luc/Developer/cctbx/boost/boost/python/override.hpp:11:
In file included from
/Users/luc/Developer/cctbx/boost/boost/python/converter/return_from_python.hpp:12:
In file included from
/Users/luc/Developer/cctbx/boost/boost/python/converter/object_manager.hpp:8:
In file included from
/Users/luc/Developer/cctbx/boost/boost/python/handle.hpp:11:
In file included from
/Users/luc/Developer/cctbx/boost/boost/python/errors.hpp:13:
In file included from
/Users/luc/Developer/cctbx/boost/boost/function/function0.hpp:11:
In file included from
/Users/luc/Developer/cctbx/boost/boost/function/detail/maybe_include.hpp:13:
In file included from
/Users/luc/Developer/cctbx/boost/boost/function/function_template.hpp:13:
In file included from
/Users/luc/Developer/cctbx/boost/boost/function/detail/prologue.hpp:17:
In file included from
/Users/luc/Developer/cctbx/boost/boost/function/function_base.hpp:22:
In file included from
/Users/luc/Developer/cctbx/boost/boost/type_traits/has_trivial_copy.hpp:15:
/Users/luc/Developer/cctbx/boost/boost/type_traits/is_pod.hpp:40:129: error:
'T' does not refer to a
      value
  ...::boost::is_scalar<T>::value, ::boost::is_void<T>::value, __is_pod(T)
>::value);
                                                                        ^
/Users/luc/Developer/cctbx/boost/boost/type_traits/is_pod.hpp:38:20: note:
declared here
template <typename T> struct is_pod_impl
                   ^
/Users/luc/Developer/cctbx/boost/boost/type_traits/is_pod.hpp:40:135: error:
type name requires a
      specifier or qualifier
  ...::boost::is_scalar<T>::value, ::boost::is_void<T>::value, __is_pod(T)
>::value);
                                                                              ^
/Users/luc/Developer/cctbx/boost/boost/type_traits/is_pod.hpp:40:135: error:
expected ')'
/Users/luc/Developer/cctbx/boost/boost/type_traits/is_pod.hpp:40:31: note: to
match this '('
    static const bool value = (::boost::type_traits::ice_or<
::boost::is_scalar<T>::value,...
                              ^
3 errors generated.

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list