Nico Rieck: this patch series fixes visibility issues on Windows as explained in <http://lists.cs.uiuc.edu/pipermail/cfe-dev/2013-August/031214.html>.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@188192 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -462,7 +462,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD
|
||||
// fpos
|
||||
|
||||
template <class _StateT>
|
||||
class _LIBCPP_TYPE_VIS fpos
|
||||
class _LIBCPP_TYPE_VIS_ONLY fpos
|
||||
{
|
||||
private:
|
||||
_StateT __st_;
|
||||
@@ -499,7 +499,7 @@ bool operator!=(const fpos<_StateT>& __x, const fpos<_StateT>& __y)
|
||||
// char_traits
|
||||
|
||||
template <class _CharT>
|
||||
struct _LIBCPP_TYPE_VIS char_traits
|
||||
struct _LIBCPP_TYPE_VIS_ONLY char_traits
|
||||
{
|
||||
typedef _CharT char_type;
|
||||
typedef int int_type;
|
||||
@@ -625,7 +625,7 @@ char_traits<_CharT>::assign(char_type* __s, size_t __n, char_type __a)
|
||||
// char_traits<char>
|
||||
|
||||
template <>
|
||||
struct _LIBCPP_TYPE_VIS char_traits<char>
|
||||
struct _LIBCPP_TYPE_VIS_ONLY char_traits<char>
|
||||
{
|
||||
typedef char char_type;
|
||||
typedef int int_type;
|
||||
@@ -681,7 +681,7 @@ struct _LIBCPP_TYPE_VIS char_traits<char>
|
||||
// char_traits<wchar_t>
|
||||
|
||||
template <>
|
||||
struct _LIBCPP_TYPE_VIS char_traits<wchar_t>
|
||||
struct _LIBCPP_TYPE_VIS_ONLY char_traits<wchar_t>
|
||||
{
|
||||
typedef wchar_t char_type;
|
||||
typedef wint_t int_type;
|
||||
@@ -738,7 +738,7 @@ struct _LIBCPP_TYPE_VIS char_traits<wchar_t>
|
||||
#ifndef _LIBCPP_HAS_NO_UNICODE_CHARS
|
||||
|
||||
template <>
|
||||
struct _LIBCPP_TYPE_VIS char_traits<char16_t>
|
||||
struct _LIBCPP_TYPE_VIS_ONLY char_traits<char16_t>
|
||||
{
|
||||
typedef char16_t char_type;
|
||||
typedef uint_least16_t int_type;
|
||||
@@ -858,7 +858,7 @@ char_traits<char16_t>::assign(char_type* __s, size_t __n, char_type __a)
|
||||
}
|
||||
|
||||
template <>
|
||||
struct _LIBCPP_TYPE_VIS char_traits<char32_t>
|
||||
struct _LIBCPP_TYPE_VIS_ONLY char_traits<char32_t>
|
||||
{
|
||||
typedef char32_t char_type;
|
||||
typedef uint_least32_t int_type;
|
||||
@@ -1003,7 +1003,7 @@ basic_string<_CharT, _Traits, _Allocator>
|
||||
operator+(const basic_string<_CharT, _Traits, _Allocator>& __x, _CharT __y);
|
||||
|
||||
template <bool>
|
||||
class __basic_string_common
|
||||
class _LIBCPP_TYPE_VIS_ONLY __basic_string_common
|
||||
{
|
||||
protected:
|
||||
void __throw_length_error() const;
|
||||
@@ -1036,7 +1036,7 @@ __basic_string_common<__b>::__throw_out_of_range() const
|
||||
#pragma warning( push )
|
||||
#pragma warning( disable: 4231 )
|
||||
#endif // _LIBCPP_MSVC
|
||||
_LIBCPP_EXTERN_TEMPLATE(class __basic_string_common<true>)
|
||||
_LIBCPP_EXTERN_TEMPLATE(class _LIBCPP_TYPE_VIS __basic_string_common<true>)
|
||||
#ifdef _LIBCPP_MSVC
|
||||
#pragma warning( pop )
|
||||
#endif // _LIBCPP_MSVC
|
||||
@@ -1057,7 +1057,7 @@ struct __padding<_CharT, 1>
|
||||
#endif // _LIBCPP_ALTERNATE_STRING_LAYOUT
|
||||
|
||||
template<class _CharT, class _Traits, class _Allocator>
|
||||
class _LIBCPP_TYPE_VIS basic_string
|
||||
class _LIBCPP_TYPE_VIS_ONLY basic_string
|
||||
: private __basic_string_common<true>
|
||||
{
|
||||
public:
|
||||
@@ -3998,45 +3998,45 @@ typedef basic_string<char32_t> u32string;
|
||||
|
||||
#endif // _LIBCPP_HAS_NO_UNICODE_CHARS
|
||||
|
||||
int stoi (const string& __str, size_t* __idx = 0, int __base = 10);
|
||||
long stol (const string& __str, size_t* __idx = 0, int __base = 10);
|
||||
unsigned long stoul (const string& __str, size_t* __idx = 0, int __base = 10);
|
||||
long long stoll (const string& __str, size_t* __idx = 0, int __base = 10);
|
||||
unsigned long long stoull(const string& __str, size_t* __idx = 0, int __base = 10);
|
||||
_LIBCPP_FUNC_VIS int stoi (const string& __str, size_t* __idx = 0, int __base = 10);
|
||||
_LIBCPP_FUNC_VIS long stol (const string& __str, size_t* __idx = 0, int __base = 10);
|
||||
_LIBCPP_FUNC_VIS unsigned long stoul (const string& __str, size_t* __idx = 0, int __base = 10);
|
||||
_LIBCPP_FUNC_VIS long long stoll (const string& __str, size_t* __idx = 0, int __base = 10);
|
||||
_LIBCPP_FUNC_VIS unsigned long long stoull(const string& __str, size_t* __idx = 0, int __base = 10);
|
||||
|
||||
float stof (const string& __str, size_t* __idx = 0);
|
||||
double stod (const string& __str, size_t* __idx = 0);
|
||||
long double stold(const string& __str, size_t* __idx = 0);
|
||||
_LIBCPP_FUNC_VIS float stof (const string& __str, size_t* __idx = 0);
|
||||
_LIBCPP_FUNC_VIS double stod (const string& __str, size_t* __idx = 0);
|
||||
_LIBCPP_FUNC_VIS long double stold(const string& __str, size_t* __idx = 0);
|
||||
|
||||
string to_string(int __val);
|
||||
string to_string(unsigned __val);
|
||||
string to_string(long __val);
|
||||
string to_string(unsigned long __val);
|
||||
string to_string(long long __val);
|
||||
string to_string(unsigned long long __val);
|
||||
string to_string(float __val);
|
||||
string to_string(double __val);
|
||||
string to_string(long double __val);
|
||||
_LIBCPP_FUNC_VIS string to_string(int __val);
|
||||
_LIBCPP_FUNC_VIS string to_string(unsigned __val);
|
||||
_LIBCPP_FUNC_VIS string to_string(long __val);
|
||||
_LIBCPP_FUNC_VIS string to_string(unsigned long __val);
|
||||
_LIBCPP_FUNC_VIS string to_string(long long __val);
|
||||
_LIBCPP_FUNC_VIS string to_string(unsigned long long __val);
|
||||
_LIBCPP_FUNC_VIS string to_string(float __val);
|
||||
_LIBCPP_FUNC_VIS string to_string(double __val);
|
||||
_LIBCPP_FUNC_VIS string to_string(long double __val);
|
||||
|
||||
int stoi (const wstring& __str, size_t* __idx = 0, int __base = 10);
|
||||
long stol (const wstring& __str, size_t* __idx = 0, int __base = 10);
|
||||
unsigned long stoul (const wstring& __str, size_t* __idx = 0, int __base = 10);
|
||||
long long stoll (const wstring& __str, size_t* __idx = 0, int __base = 10);
|
||||
unsigned long long stoull(const wstring& __str, size_t* __idx = 0, int __base = 10);
|
||||
_LIBCPP_FUNC_VIS int stoi (const wstring& __str, size_t* __idx = 0, int __base = 10);
|
||||
_LIBCPP_FUNC_VIS long stol (const wstring& __str, size_t* __idx = 0, int __base = 10);
|
||||
_LIBCPP_FUNC_VIS unsigned long stoul (const wstring& __str, size_t* __idx = 0, int __base = 10);
|
||||
_LIBCPP_FUNC_VIS long long stoll (const wstring& __str, size_t* __idx = 0, int __base = 10);
|
||||
_LIBCPP_FUNC_VIS unsigned long long stoull(const wstring& __str, size_t* __idx = 0, int __base = 10);
|
||||
|
||||
float stof (const wstring& __str, size_t* __idx = 0);
|
||||
double stod (const wstring& __str, size_t* __idx = 0);
|
||||
long double stold(const wstring& __str, size_t* __idx = 0);
|
||||
_LIBCPP_FUNC_VIS float stof (const wstring& __str, size_t* __idx = 0);
|
||||
_LIBCPP_FUNC_VIS double stod (const wstring& __str, size_t* __idx = 0);
|
||||
_LIBCPP_FUNC_VIS long double stold(const wstring& __str, size_t* __idx = 0);
|
||||
|
||||
wstring to_wstring(int __val);
|
||||
wstring to_wstring(unsigned __val);
|
||||
wstring to_wstring(long __val);
|
||||
wstring to_wstring(unsigned long __val);
|
||||
wstring to_wstring(long long __val);
|
||||
wstring to_wstring(unsigned long long __val);
|
||||
wstring to_wstring(float __val);
|
||||
wstring to_wstring(double __val);
|
||||
wstring to_wstring(long double __val);
|
||||
_LIBCPP_FUNC_VIS wstring to_wstring(int __val);
|
||||
_LIBCPP_FUNC_VIS wstring to_wstring(unsigned __val);
|
||||
_LIBCPP_FUNC_VIS wstring to_wstring(long __val);
|
||||
_LIBCPP_FUNC_VIS wstring to_wstring(unsigned long __val);
|
||||
_LIBCPP_FUNC_VIS wstring to_wstring(long long __val);
|
||||
_LIBCPP_FUNC_VIS wstring to_wstring(unsigned long long __val);
|
||||
_LIBCPP_FUNC_VIS wstring to_wstring(float __val);
|
||||
_LIBCPP_FUNC_VIS wstring to_wstring(double __val);
|
||||
_LIBCPP_FUNC_VIS wstring to_wstring(long double __val);
|
||||
|
||||
template<class _CharT, class _Traits, class _Allocator>
|
||||
const typename basic_string<_CharT, _Traits, _Allocator>::size_type
|
||||
@@ -4050,7 +4050,7 @@ size_t _LIBCPP_INLINE_VISIBILITY __do_string_hash(_Ptr __p, _Ptr __e)
|
||||
}
|
||||
|
||||
template<class _CharT, class _Traits, class _Allocator>
|
||||
struct _LIBCPP_TYPE_VIS hash<basic_string<_CharT, _Traits, _Allocator> >
|
||||
struct _LIBCPP_TYPE_VIS_ONLY hash<basic_string<_CharT, _Traits, _Allocator> >
|
||||
: public unary_function<basic_string<_CharT, _Traits, _Allocator>, size_t>
|
||||
{
|
||||
size_t
|
||||
@@ -4138,8 +4138,8 @@ namespace literals
|
||||
}
|
||||
#endif
|
||||
|
||||
_LIBCPP_EXTERN_TEMPLATE(class basic_string<char>)
|
||||
_LIBCPP_EXTERN_TEMPLATE(class basic_string<wchar_t>)
|
||||
_LIBCPP_EXTERN_TEMPLATE(class _LIBCPP_TYPE_VIS basic_string<char>)
|
||||
_LIBCPP_EXTERN_TEMPLATE(class _LIBCPP_TYPE_VIS basic_string<wchar_t>)
|
||||
|
||||
extern template
|
||||
string
|
||||
|
||||
Reference in New Issue
Block a user