[LLVMbugs] [Bug 12032] New: libc++ r150884 fails to build with clang r150884 due to deleted __nat destructor in type_traits
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Sat Feb 18 11:02:49 PST 2012
http://llvm.org/bugs/show_bug.cgi?id=12032
Bug #: 12032
Summary: libc++ r150884 fails to build with clang r150884 due
to deleted __nat destructor in type_traits
Product: libc++
Version: unspecified
Platform: Macintosh
OS/Version: MacOS X
Status: NEW
Keywords: compile-fail
Severity: normal
Priority: P
Component: All Bugs
AssignedTo: hhinnant at apple.com
ReportedBy: abigagli at gmail.com
CC: llvmbugs at cs.uiuc.edu
Classification: Unclassified
On lion 10.7.3, libc++ @r150884, clang++ just built from source @r150884:
export TRIPLE=-apple-
export CXX=$HOME/LLVM-CURRENT/bin/clang++
export CC=$CXX
cd lib
./buildit
.
.
.
+ for FILE in '../src/*.cpp'
+ /Users/abigagli/LLVM-CURRENT/bin/clang++ -c -g -Os -arch i386 -arch x86_64
-std=c++0x -fstrict-aliasing -Wall -Wextra -Wshadow -Wconversion -Wnewline-eof
-Wpadded -Wmissing-prototypes -Wstrict-aliasing=2 -Wstrict-overflow=4
-nostdinc++ -I../include ../src/locale.cpp
In file included from ../src/locale.cpp:10:
In file included from ../include/string:434:
In file included from ../include/algorithm:591:
../include/type_traits:3048:22: error: attempt to use a deleted function
typedef decltype(swap(_VSTD::declval<_Tp&>(), _VSTD::declval<_Tp&>()))
type;
^
../include/type_traits:3056:48: note: in instantiation of template class
'std::__1::__detail::__swappable<std::__1::__sso_allocator<std::__1::locale::facet
*, 28> >' requested here
: public integral_constant<bool, __detail::__swappable<_Tp>::value>
^
../include/type_traits:3077:41: note: in instantiation of template class
'std::__1::__is_swappable<std::__1::__sso_allocator<std::__1::locale::facet *,
28> >' requested here
: public __is_nothrow_swappable_imp<__is_swappable<_Tp>::value, _Tp>
^
../include/vector:391:13: note: in instantiation of template class
'std::__1::__is_nothrow_swappable<std::__1::__sso_allocator<std::__1::locale::facet
*, 28> >' requested here
__is_nothrow_swappable<allocator_type>::value)
^
../include/__config:238:34: note: expanded from macro '_NOEXCEPT_'
# define _NOEXCEPT_(x) noexcept(x)
^
../include/vector:484:15: note: in instantiation of template class
'std::__1::__vector_base<std::__1::locale::facet *,
std::__1::__sso_allocator<std::__1::locale::facet *, 28> >' requested
here
: private __vector_base<_Tp, _Allocator>
^
../src/locale.cpp:87:49: note: in instantiation of template class
'std::__1::vector<std::__1::locale::facet *,
std::__1::__sso_allocator<std::__1::locale::facet *, 28> >' requested
here
vector<facet*, __sso_allocator<facet*, N> > facets_;
^
../include/type_traits:832:5: note: function has been explicitly marked deleted
here
~__nat() = delete;
^
1 error generated.
Everything builds fine with Xcode 4.3's clang.
The following patch
Index: ../include/type_traits
===================================================================
--- ../include/type_traits (revision 150884)
+++ ../include/type_traits (working copy)
@@ -830,7 +830,7 @@
__nat() = delete;
__nat(const __nat&) = delete;
__nat& operator=(const __nat&) = delete;
- ~__nat() = delete;
+ //~__nat() = delete;
#endif
};
seems to solve the problem, but I don't think that's the right thing to do...
--
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