Browse Source

http://llvm.org/bugs/show_bug.cgi?id=10390

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@135393 91177308-0d34-0410-b5e6-96231b3b80d8
Howard Hinnant 14 năm trước cách đây
mục cha
commit
464aa5cad3
3 tập tin đã thay đổi với 51 bổ sung0 xóa
  1. 8 0
      include/bitset
  2. 6 0
      include/memory
  3. 37 0
      include/string

+ 8 - 0
include/bitset

@@ -1033,6 +1033,14 @@ struct _LIBCPP_VISIBLE hash<bitset<_Size> >
         {return __bs.__hash_code();}
 };
 
+template <class _CharT, class _Traits, size_t _Size>
+basic_istream<_CharT, _Traits>&
+operator>>(basic_istream<_CharT, _Traits>& __is, bitset<_Size>& __x);
+
+template <class _CharT, class _Traits, size_t _Size>
+basic_ostream<_CharT, _Traits>&
+operator<<(basic_ostream<_CharT, _Traits>& __os, const bitset<_Size>& __x);
+
 _LIBCPP_END_NAMESPACE_STD
 
 #endif  // _LIBCPP_BITSET

+ 6 - 0
include/memory

@@ -595,6 +595,7 @@ void* align(size_t alignment, size_t size, void*& ptr, size_t& space);
 #include <limits>
 #include <iterator>
 #include <__functional_base>
+#include <iosfwd>
 #if defined(_LIBCPP_NO_EXCEPTIONS)
     #include <cassert>
 #endif
@@ -4148,6 +4149,11 @@ struct _LIBCPP_VISIBLE hash<shared_ptr<_Tp> >
     }
 };
 
+template<class _CharT, class _Traits, class _Y>
+inline _LIBCPP_INLINE_VISIBILITY
+basic_ostream<_CharT, _Traits>&
+operator<<(basic_ostream<_CharT, _Traits>& __os, shared_ptr<_Y> const& __p);
+
 //enum class
 struct _LIBCPP_VISIBLE pointer_safety
 {

+ 37 - 0
include/string

@@ -3966,6 +3966,43 @@ hash<basic_string<_CharT, _Traits, _Allocator> >::operator()(
     return __r;
 }
 
+template<class _CharT, class _Traits, class _Allocator>
+basic_ostream<_CharT, _Traits>&
+operator<<(basic_ostream<_CharT, _Traits>& __os,
+           const basic_string<_CharT, _Traits, _Allocator>& __str);
+
+template<class _CharT, class _Traits, class _Allocator>
+basic_istream<_CharT, _Traits>&
+operator>>(basic_istream<_CharT, _Traits>& __is,
+           basic_string<_CharT, _Traits, _Allocator>& __str);
+
+template<class _CharT, class _Traits, class _Allocator>
+basic_istream<_CharT, _Traits>&
+getline(basic_istream<_CharT, _Traits>& __is,
+        basic_string<_CharT, _Traits, _Allocator>& __str, _CharT __dlm);
+
+template<class _CharT, class _Traits, class _Allocator>
+inline _LIBCPP_INLINE_VISIBILITY
+basic_istream<_CharT, _Traits>&
+getline(basic_istream<_CharT, _Traits>& __is,
+        basic_string<_CharT, _Traits, _Allocator>& __str);
+
+#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
+
+template<class _CharT, class _Traits, class _Allocator>
+inline _LIBCPP_INLINE_VISIBILITY
+basic_istream<_CharT, _Traits>&
+getline(basic_istream<_CharT, _Traits>&& __is,
+        basic_string<_CharT, _Traits, _Allocator>& __str, _CharT __dlm);
+
+template<class _CharT, class _Traits, class _Allocator>
+inline _LIBCPP_INLINE_VISIBILITY
+basic_istream<_CharT, _Traits>&
+getline(basic_istream<_CharT, _Traits>&& __is,
+        basic_string<_CharT, _Traits, _Allocator>& __str);
+
+#endif  // _LIBCPP_HAS_NO_RVALUE_REFERENCES
+
 extern template class basic_string<char>;
 extern template class basic_string<wchar_t>;