From a75c1bf9f620dd99bb6763a941453209ec329fb5 Mon Sep 17 00:00:00 2001 From: Eric Fiselier Date: Wed, 14 Sep 2016 23:52:01 +0000 Subject: [PATCH] Revert r280944 - Added 'inline' attribute to basic_string's destructor This patch causes a couple of issues: 1) It triggers http://llvm.org/PR30341. Although the bug is not truly a libc++ bug it breaks the LLVM build using libc++. Reverting this patch is only a temporary workaround until Clang is fixed. 2) It adds yet another ABI incompatibility when libc++.so is compiled with GCC. Specifically GCC doesn't ignore the _LIBCPP_INLINE_VISIBILITY on the out-of-line definition when compiling the dylib. This causes the externally instantiated ~basic_string symbol to have hidden visibility. This patch should be recommitted after addressing (1) and (2). (2) can be fixed by adding _LIBCPP_EXTERN_TEMPLATE_INLINE_VISIBILITY which is defined as __attribute__((visibility("default"), always_inline)) as opposed to _LIBCPP_INLINE_VISIBILITY which makes the symbol hidden. llvm-svn: 281562 --- libcxx/include/string | 1 - 1 file changed, 1 deletion(-) diff --git a/libcxx/include/string b/libcxx/include/string index 1042ee6bbad5..b9e044e82d42 100644 --- a/libcxx/include/string +++ b/libcxx/include/string @@ -1798,7 +1798,6 @@ basic_string<_CharT, _Traits, _Allocator>::basic_string(initializer_list -inline _LIBCPP_INLINE_VISIBILITY basic_string<_CharT, _Traits, _Allocator>::~basic_string() { #if _LIBCPP_DEBUG_LEVEL >= 2