Provide a way to disable use of extern templates in libc++. This is intended for the clients of libc++, not the libc++ build. The dylib should always contain the extern templates. To disable the client needs to put -D'_LIBCPP_EXTERN_TEMPLATE(...)=' on the command line.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@167486 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/include/streambuf b/include/streambuf
index e34ad23..d688024 100644
--- a/include/streambuf
+++ b/include/streambuf
@@ -553,11 +553,11 @@
return traits_type::eof();
}
-extern template class basic_streambuf<char>;
-extern template class basic_streambuf<wchar_t>;
+_LIBCPP_EXTERN_TEMPLATE(class basic_streambuf<char>)
+_LIBCPP_EXTERN_TEMPLATE(class basic_streambuf<wchar_t>)
-extern template class basic_ios<char>;
-extern template class basic_ios<wchar_t>;
+_LIBCPP_EXTERN_TEMPLATE(class basic_ios<char>)
+_LIBCPP_EXTERN_TEMPLATE(class basic_ios<wchar_t>)
_LIBCPP_END_NAMESPACE_STD