Author: hhinnant
Date: Thu Aug 29 15:56:53 2013
New Revision: 189610

URL: http://llvm.org/viewvc/llvm-project?rev=189610&view=rev
Log:
Turn off extern templates for most uses.  It is causing more problems than it 
is worth.  The extern templates will still be built into the dylib, mainly for 
ABI stability purposes.  And the client can still turn these back on with a 
#define if desire.  This fixes http://llvm.org/bugs/show_bug.cgi?id=17027.  
However there's no associated test for the test suite because 
http://llvm.org/bugs/show_bug.cgi?id=17027 needs mismatched dylib and headers 
to fire.

Modified:
    libcxx/trunk/include/__config
    libcxx/trunk/src/algorithm.cpp
    libcxx/trunk/src/ios.cpp
    libcxx/trunk/src/locale.cpp
    libcxx/trunk/src/string.cpp
    libcxx/trunk/src/valarray.cpp

Modified: libcxx/trunk/include/__config
URL: 
http://llvm.org/viewvc/llvm-project/libcxx/trunk/include/__config?rev=189610&r1=189609&r2=189610&view=diff
==============================================================================
--- libcxx/trunk/include/__config (original)
+++ libcxx/trunk/include/__config Thu Aug 29 15:56:53 2013
@@ -538,7 +538,7 @@ template <unsigned> struct __static_asse
 #endif
 
 #ifndef _LIBCPP_EXTERN_TEMPLATE
-#define _LIBCPP_EXTERN_TEMPLATE(...) extern template __VA_ARGS__;
+#define _LIBCPP_EXTERN_TEMPLATE(...)
 #endif
 
 #ifndef _LIBCPP_EXTERN_TEMPLATE2

Modified: libcxx/trunk/src/algorithm.cpp
URL: 
http://llvm.org/viewvc/llvm-project/libcxx/trunk/src/algorithm.cpp?rev=189610&r1=189609&r2=189610&view=diff
==============================================================================
--- libcxx/trunk/src/algorithm.cpp (original)
+++ libcxx/trunk/src/algorithm.cpp Thu Aug 29 15:56:53 2013
@@ -7,6 +7,7 @@
 //
 
//===----------------------------------------------------------------------===//
 
+#define _LIBCPP_EXTERN_TEMPLATE(...) extern template __VA_ARGS__;
 #include "algorithm"
 #include "random"
 #include "mutex"

Modified: libcxx/trunk/src/ios.cpp
URL: 
http://llvm.org/viewvc/llvm-project/libcxx/trunk/src/ios.cpp?rev=189610&r1=189609&r2=189610&view=diff
==============================================================================
--- libcxx/trunk/src/ios.cpp (original)
+++ libcxx/trunk/src/ios.cpp Thu Aug 29 15:56:53 2013
@@ -7,6 +7,8 @@
 //
 
//===----------------------------------------------------------------------===//
 
+#define _LIBCPP_EXTERN_TEMPLATE(...) extern template __VA_ARGS__;
+
 #include "ios"
 #include "streambuf"
 #include "istream"

Modified: libcxx/trunk/src/locale.cpp
URL: 
http://llvm.org/viewvc/llvm-project/libcxx/trunk/src/locale.cpp?rev=189610&r1=189609&r2=189610&view=diff
==============================================================================
--- libcxx/trunk/src/locale.cpp (original)
+++ libcxx/trunk/src/locale.cpp Thu Aug 29 15:56:53 2013
@@ -7,6 +7,8 @@
 //
 
//===----------------------------------------------------------------------===//
 
+#define _LIBCPP_EXTERN_TEMPLATE(...) extern template __VA_ARGS__;
+
 // On Solaris, we need to define something to make the C99 parts of localeconv
 // visible.
 #ifdef __sun__

Modified: libcxx/trunk/src/string.cpp
URL: 
http://llvm.org/viewvc/llvm-project/libcxx/trunk/src/string.cpp?rev=189610&r1=189609&r2=189610&view=diff
==============================================================================
--- libcxx/trunk/src/string.cpp (original)
+++ libcxx/trunk/src/string.cpp Thu Aug 29 15:56:53 2013
@@ -7,6 +7,8 @@
 //
 
//===----------------------------------------------------------------------===//
 
+#define _LIBCPP_EXTERN_TEMPLATE(...) extern template __VA_ARGS__;
+
 #include "string"
 #include "cstdlib"
 #include "cwchar"

Modified: libcxx/trunk/src/valarray.cpp
URL: 
http://llvm.org/viewvc/llvm-project/libcxx/trunk/src/valarray.cpp?rev=189610&r1=189609&r2=189610&view=diff
==============================================================================
--- libcxx/trunk/src/valarray.cpp (original)
+++ libcxx/trunk/src/valarray.cpp Thu Aug 29 15:56:53 2013
@@ -7,6 +7,8 @@
 //
 
//===----------------------------------------------------------------------===//
 
+#define _LIBCPP_EXTERN_TEMPLATE(...) extern template __VA_ARGS__;
+
 #include "valarray"
 
 _LIBCPP_BEGIN_NAMESPACE_STD


_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to