| OLD | NEW |
| 1 //===------------------------- string.cpp ---------------------------------===// | 1 //===------------------------- string.cpp ---------------------------------===// |
| 2 // | 2 // |
| 3 // The LLVM Compiler Infrastructure | 3 // The LLVM Compiler Infrastructure |
| 4 // | 4 // |
| 5 // This file is dual licensed under the MIT and the University of Illinois Open | 5 // This file is dual licensed under the MIT and the University of Illinois Open |
| 6 // Source Licenses. See LICENSE.TXT for details. | 6 // Source Licenses. See LICENSE.TXT for details. |
| 7 // | 7 // |
| 8 //===----------------------------------------------------------------------===// | 8 //===----------------------------------------------------------------------===// |
| 9 | 9 |
| 10 #include "string" | 10 #include "string" |
| 11 #include "cstdlib" | 11 #include "cstdlib" |
| 12 #include "cwchar" | 12 #include "cwchar" |
| 13 #include "cerrno" | 13 #include "cerrno" |
| 14 #include "limits" | 14 #include "limits" |
| 15 #include "stdexcept" | 15 #include "stdexcept" |
| 16 #ifdef _LIBCPP_MSVCRT | 16 #ifdef _LIBCPP_MSVCRT |
| 17 #include "support/win32/support.h" | 17 #include "support/win32/support.h" |
| 18 #endif // _LIBCPP_MSVCRT | 18 #endif // _LIBCPP_MSVCRT |
| 19 #include <stdio.h> | 19 #include <stdio.h> |
| 20 | 20 |
| 21 _LIBCPP_BEGIN_NAMESPACE_STD | 21 _LIBCPP_BEGIN_NAMESPACE_STD |
| 22 | 22 |
| 23 template class __basic_string_common<true>; | 23 template class __basic_string_common<true>; |
| 24 | 24 |
| 25 template class basic_string<char>; | 25 template class basic_string<char>; |
| 26 template class basic_string<wchar_t>; | 26 template class basic_string<wchar_t>; |
| 27 | 27 |
| 28 template | 28 template |
| 29 string | 29 string |
| 30 operator+<char, char_traits<char>, allocator<char> >(char const*, string con
st&); | 30 operator+<char, char_traits<char>, counting_allocator<char, allocation_group
::string> >(char const*, string const&); |
| 31 | 31 |
| 32 namespace | 32 namespace |
| 33 { | 33 { |
| 34 | 34 |
| 35 template<typename T> | 35 template<typename T> |
| 36 inline | 36 inline |
| 37 void throw_helper( const string& msg ) | 37 void throw_helper( const string& msg ) |
| 38 { | 38 { |
| 39 #ifndef _LIBCPP_NO_EXCEPTIONS | 39 #ifndef _LIBCPP_NO_EXCEPTIONS |
| 40 throw T( msg ); | 40 throw T( msg ); |
| (...skipping 478 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 519 wstring to_wstring(double val) | 519 wstring to_wstring(double val) |
| 520 { | 520 { |
| 521 return as_string(get_swprintf(), initial_string<wstring, double>()(), L"%f",
val); | 521 return as_string(get_swprintf(), initial_string<wstring, double>()(), L"%f",
val); |
| 522 } | 522 } |
| 523 | 523 |
| 524 wstring to_wstring(long double val) | 524 wstring to_wstring(long double val) |
| 525 { | 525 { |
| 526 return as_string(get_swprintf(), initial_string<wstring, long double>()(), L
"%Lf", val); | 526 return as_string(get_swprintf(), initial_string<wstring, long double>()(), L
"%Lf", val); |
| 527 } | 527 } |
| 528 _LIBCPP_END_NAMESPACE_STD | 528 _LIBCPP_END_NAMESPACE_STD |
| OLD | NEW |