From a8d1182f661ccecd99efd4e543fddf3172c67a95 Mon Sep 17 00:00:00 2001 From: Arthur O'Dwyer Date: Tue, 15 Jun 2021 12:47:05 -0400 Subject: [PATCH] [libc++] Remove some _LIBCPP_CXX03_LANG from iostreams headers. With the STL containers, I didn't enable move operations in C++03 mode because that would change the overload resolution for things that today are copy operations. With iostreams, though, the copy operations aren't present at all, and so I see no problem with enabling move operations even in (Clang's greatly extended) C++03 mode. Clang's C++03 mode does not support delegating constructors. Differential Revision: https://reviews.llvm.org/D104310 --- libcxx/include/fstream | 29 +-------------- libcxx/include/ios | 2 -- libcxx/include/istream | 19 +--------- libcxx/include/ostream | 14 ++------ libcxx/include/sstream | 42 +++++----------------- libcxx/include/string | 4 --- .../fstreams/filebuf.assign/move_assign.pass.cpp | 2 -- .../fstreams/filebuf.cons/move.pass.cpp | 6 ++-- .../fstreams/fstream.assign/move_assign.pass.cpp | 2 -- .../fstreams/fstream.cons/move.pass.cpp | 6 ++-- .../fstreams/ifstream.assign/move_assign.pass.cpp | 1 - .../fstreams/ifstream.cons/move.pass.cpp | 5 ++- .../fstreams/ofstream.assign/move_assign.pass.cpp | 2 -- .../fstreams/ofstream.cons/move.pass.cpp | 6 ++-- .../iostream.assign/move_assign.pass.cpp | 2 -- .../iostreamclass/iostream.cons/move.pass.cpp | 2 -- .../istream/istream.assign/move_assign.pass.cpp | 2 -- .../istream/istream.cons/copy.fail.cpp | 5 --- .../istream/istream.cons/move.pass.cpp | 2 -- .../ostream.assign/move_assign.pass.cpp | 2 -- .../output.streams/ostream.cons/move.pass.cpp | 2 -- .../is_error_code_enum_io_errc.pass.cpp | 2 -- .../istringstream.assign/move.pass.cpp | 2 -- .../istringstream/istringstream.cons/move.pass.cpp | 2 -- .../ostringstream.assign/move.pass.cpp | 2 -- .../ostringstream/ostringstream.cons/move.pass.cpp | 2 -- .../stringbuf/stringbuf.cons/move.pass.cpp | 12 +++---- .../string.streams/stringstream.cons/move.pass.cpp | 2 -- .../stringstream.assign/move.pass.cpp | 2 -- .../string.io/get_line_delim_rv.pass.cpp | 6 ++-- .../string.io/get_line_rv.pass.cpp | 6 ++-- 31 files changed, 31 insertions(+), 164 deletions(-) diff --git a/libcxx/include/fstream b/libcxx/include/fstream index 09af0d9..c522b8a 100644 --- a/libcxx/include/fstream +++ b/libcxx/include/fstream @@ -219,16 +219,12 @@ public: // 27.9.1.2 Constructors/destructor: basic_filebuf(); -#ifndef _LIBCPP_CXX03_LANG basic_filebuf(basic_filebuf&& __rhs); -#endif virtual ~basic_filebuf(); // 27.9.1.3 Assign/swap: -#ifndef _LIBCPP_CXX03_LANG _LIBCPP_INLINE_VISIBILITY basic_filebuf& operator=(basic_filebuf&& __rhs); -#endif void swap(basic_filebuf& __rhs); // 27.9.1.4 Members: @@ -318,8 +314,6 @@ basic_filebuf<_CharT, _Traits>::basic_filebuf() setbuf(nullptr, 4096); } -#ifndef _LIBCPP_CXX03_LANG - template basic_filebuf<_CharT, _Traits>::basic_filebuf(basic_filebuf&& __rhs) : basic_streambuf<_CharT, _Traits>(__rhs) @@ -394,8 +388,6 @@ basic_filebuf<_CharT, _Traits>::operator=(basic_filebuf&& __rhs) return *this; } -#endif // _LIBCPP_CXX03_LANG - template basic_filebuf<_CharT, _Traits>::~basic_filebuf() { @@ -1164,13 +1156,10 @@ public: : basic_ifstream(__p.c_str(), __mode) {} #endif // _LIBCPP_STD_VER >= 17 #endif -#ifndef _LIBCPP_CXX03_LANG _LIBCPP_INLINE_VISIBILITY basic_ifstream(basic_ifstream&& __rhs); - _LIBCPP_INLINE_VISIBILITY basic_ifstream& operator=(basic_ifstream&& __rhs); -#endif _LIBCPP_INLINE_VISIBILITY void swap(basic_ifstream& __rhs); @@ -1240,8 +1229,6 @@ basic_ifstream<_CharT, _Traits>::basic_ifstream(const string& __s, ios_base::ope } #endif -#ifndef _LIBCPP_CXX03_LANG - template inline basic_ifstream<_CharT, _Traits>::basic_ifstream(basic_ifstream&& __rhs) @@ -1261,8 +1248,6 @@ basic_ifstream<_CharT, _Traits>::operator=(basic_ifstream&& __rhs) return *this; } -#endif // _LIBCPP_CXX03_LANG - template inline void @@ -1379,13 +1364,10 @@ public: : basic_ofstream(__p.c_str(), __mode) {} #endif // _LIBCPP_STD_VER >= 17 -#ifndef _LIBCPP_CXX03_LANG _LIBCPP_INLINE_VISIBILITY basic_ofstream(basic_ofstream&& __rhs); - _LIBCPP_INLINE_VISIBILITY basic_ofstream& operator=(basic_ofstream&& __rhs); -#endif _LIBCPP_INLINE_VISIBILITY void swap(basic_ofstream& __rhs); @@ -1454,8 +1436,6 @@ basic_ofstream<_CharT, _Traits>::basic_ofstream(const string& __s, ios_base::ope } #endif -#ifndef _LIBCPP_CXX03_LANG - template inline basic_ofstream<_CharT, _Traits>::basic_ofstream(basic_ofstream&& __rhs) @@ -1475,8 +1455,6 @@ basic_ofstream<_CharT, _Traits>::operator=(basic_ofstream&& __rhs) return *this; } -#endif // _LIBCPP_CXX03_LANG - template inline void @@ -1595,13 +1573,12 @@ public: #endif // _LIBCPP_STD_VER >= 17 #endif -#ifndef _LIBCPP_CXX03_LANG _LIBCPP_INLINE_VISIBILITY basic_fstream(basic_fstream&& __rhs); _LIBCPP_INLINE_VISIBILITY basic_fstream& operator=(basic_fstream&& __rhs); -#endif + _LIBCPP_INLINE_VISIBILITY void swap(basic_fstream& __rhs); @@ -1668,8 +1645,6 @@ basic_fstream<_CharT, _Traits>::basic_fstream(const string& __s, ios_base::openm } #endif -#ifndef _LIBCPP_CXX03_LANG - template inline basic_fstream<_CharT, _Traits>::basic_fstream(basic_fstream&& __rhs) @@ -1689,8 +1664,6 @@ basic_fstream<_CharT, _Traits>::operator=(basic_fstream&& __rhs) return *this; } -#endif // _LIBCPP_CXX03_LANG - template inline void diff --git a/libcxx/include/ios b/libcxx/include/ios index eefb58f..3128bca 100644 --- a/libcxx/include/ios +++ b/libcxx/include/ios @@ -662,10 +662,8 @@ protected: _LIBCPP_INLINE_VISIBILITY void move(basic_ios& __rhs); -#ifndef _LIBCPP_CXX03_LANG _LIBCPP_INLINE_VISIBILITY void move(basic_ios&& __rhs) {move(__rhs);} -#endif _LIBCPP_INLINE_VISIBILITY void swap(basic_ios& __rhs) _NOEXCEPT; _LIBCPP_INLINE_VISIBILITY diff --git a/libcxx/include/istream b/libcxx/include/istream index 5312807..17ca683 100644 --- a/libcxx/include/istream +++ b/libcxx/include/istream @@ -192,14 +192,12 @@ public: { this->init(__sb); } virtual ~basic_istream(); protected: -#ifndef _LIBCPP_CXX03_LANG inline _LIBCPP_INLINE_VISIBILITY basic_istream(basic_istream&& __rhs); // 27.7.1.1.2 Assign/swap: inline _LIBCPP_INLINE_VISIBILITY basic_istream& operator=(basic_istream&& __rhs); -#endif inline _LIBCPP_HIDE_FROM_ABI_AFTER_V1 void swap(basic_istream& __rhs) { @@ -207,10 +205,8 @@ protected: basic_ios::swap(__rhs); } -#ifndef _LIBCPP_CXX03_LANG basic_istream (const basic_istream& __rhs) = delete; basic_istream& operator=(const basic_istream& __rhs) = delete; -#endif public: // 27.7.1.1.3 Prefix/suffix: @@ -333,8 +329,6 @@ basic_istream<_CharT, _Traits>::sentry::sentry(basic_istream<_CharT, _Traits>& _ __is.setstate(ios_base::failbit); } -#ifndef _LIBCPP_CXX03_LANG - template basic_istream<_CharT, _Traits>::basic_istream(basic_istream&& __rhs) : __gc_(__rhs.__gc_) @@ -351,8 +345,6 @@ basic_istream<_CharT, _Traits>::operator=(basic_istream&& __rhs) return *this; } -#endif // _LIBCPP_CXX03_LANG - template basic_istream<_CharT, _Traits>::~basic_istream() { @@ -1416,21 +1408,18 @@ public: virtual ~basic_iostream(); protected: -#ifndef _LIBCPP_CXX03_LANG inline _LIBCPP_INLINE_VISIBILITY basic_iostream(basic_iostream&& __rhs); // assign/swap inline _LIBCPP_INLINE_VISIBILITY basic_iostream& operator=(basic_iostream&& __rhs); -#endif + inline _LIBCPP_HIDE_FROM_ABI_AFTER_V1 void swap(basic_iostream& __rhs) { basic_istream::swap(__rhs); } }; -#ifndef _LIBCPP_CXX03_LANG - template basic_iostream<_CharT, _Traits>::basic_iostream(basic_iostream&& __rhs) : basic_istream<_CharT, _Traits>(_VSTD::move(__rhs)) @@ -1445,8 +1434,6 @@ basic_iostream<_CharT, _Traits>::operator=(basic_iostream&& __rhs) return *this; } -#endif // _LIBCPP_CXX03_LANG - template basic_iostream<_CharT, _Traits>::~basic_iostream() { @@ -1570,8 +1557,6 @@ getline(basic_istream<_CharT, _Traits>& __is, return getline(__is, __str, __is.widen('\n')); } -#ifndef _LIBCPP_CXX03_LANG - template inline _LIBCPP_INLINE_VISIBILITY basic_istream<_CharT, _Traits>& @@ -1590,8 +1575,6 @@ getline(basic_istream<_CharT, _Traits>&& __is, return getline(__is, __str, __is.widen('\n')); } -#endif // _LIBCPP_CXX03_LANG - template basic_istream<_CharT, _Traits>& operator>>(basic_istream<_CharT, _Traits>& __is, bitset<_Size>& __x) diff --git a/libcxx/include/ostream b/libcxx/include/ostream index 81ba565..efeaee2 100644 --- a/libcxx/include/ostream +++ b/libcxx/include/ostream @@ -165,27 +165,21 @@ public: { this->init(__sb); } virtual ~basic_ostream(); protected: -#ifndef _LIBCPP_CXX03_LANG inline _LIBCPP_INLINE_VISIBILITY basic_ostream(basic_ostream&& __rhs); // 27.7.2.3 Assign/swap inline _LIBCPP_INLINE_VISIBILITY basic_ostream& operator=(basic_ostream&& __rhs); -#endif + inline _LIBCPP_HIDE_FROM_ABI_AFTER_V1 void swap(basic_ostream& __rhs) { basic_ios::swap(__rhs); } -#ifndef _LIBCPP_CXX03_LANG basic_ostream (const basic_ostream& __rhs) = delete; basic_ostream& operator=(const basic_ostream& __rhs) = delete; -#else - basic_ostream (const basic_ostream& __rhs); // not defined - basic_ostream& operator=(const basic_ostream& __rhs); // not defined -#endif -public: +public: // 27.7.2.4 Prefix/suffix: class _LIBCPP_TEMPLATE_VIS sentry; @@ -291,8 +285,6 @@ basic_ostream<_CharT, _Traits>::sentry::~sentry() } } -#ifndef _LIBCPP_CXX03_LANG - template basic_ostream<_CharT, _Traits>::basic_ostream(basic_ostream&& __rhs) { @@ -307,8 +299,6 @@ basic_ostream<_CharT, _Traits>::operator=(basic_ostream&& __rhs) return *this; } -#endif // _LIBCPP_CXX03_LANG - template basic_ostream<_CharT, _Traits>::~basic_ostream() { diff --git a/libcxx/include/sstream b/libcxx/include/sstream index 0b614a0..fbe5ffc 100644 --- a/libcxx/include/sstream +++ b/libcxx/include/sstream @@ -219,19 +219,13 @@ private: public: // 30.8.2.1 [stringbuf.cons], constructors -#ifndef _LIBCPP_CXX03_LANG _LIBCPP_INLINE_VISIBILITY - basic_stringbuf() : basic_stringbuf(ios_base::in | ios_base::out) {} + basic_stringbuf() + : __hm_(nullptr), __mode_(ios_base::in | ios_base::out) {} _LIBCPP_INLINE_VISIBILITY explicit basic_stringbuf(ios_base::openmode __wch) : __hm_(nullptr), __mode_(__wch) {} -#else - _LIBCPP_INLINE_VISIBILITY - explicit basic_stringbuf(ios_base::openmode __wch = ios_base::in | - ios_base::out) - : __hm_(nullptr), __mode_(__wch) {} -#endif _LIBCPP_INLINE_VISIBILITY explicit basic_stringbuf(const string_type& __s, @@ -643,18 +637,13 @@ private: public: // 30.8.3.1 [istringstream.cons], constructors -#ifndef _LIBCPP_CXX03_LANG _LIBCPP_INLINE_VISIBILITY - basic_istringstream() : basic_istringstream(ios_base::in) {} + basic_istringstream() + : basic_istream<_CharT, _Traits>(&__sb_), __sb_(ios_base::in) {} _LIBCPP_INLINE_VISIBILITY explicit basic_istringstream(ios_base::openmode __wch) : basic_istream<_CharT, _Traits>(&__sb_), __sb_(__wch | ios_base::in) {} -#else - _LIBCPP_INLINE_VISIBILITY - explicit basic_istringstream(ios_base::openmode __wch = ios_base::in) - : basic_istream<_CharT, _Traits>(&__sb_), __sb_(__wch | ios_base::in) {} -#endif _LIBCPP_INLINE_VISIBILITY explicit basic_istringstream(const string_type& __s, @@ -728,20 +717,13 @@ private: public: // 30.8.4.1 [ostringstream.cons], constructors -#ifndef _LIBCPP_CXX03_LANG _LIBCPP_INLINE_VISIBILITY - basic_ostringstream() : basic_ostringstream(ios_base::out) {} + basic_ostringstream() + : basic_ostream<_CharT, _Traits>(&__sb_), __sb_(ios_base::out) {} _LIBCPP_INLINE_VISIBILITY explicit basic_ostringstream(ios_base::openmode __wch) - : basic_ostream<_CharT, _Traits>(&__sb_), - __sb_(__wch | ios_base::out) {} -#else - _LIBCPP_INLINE_VISIBILITY - explicit basic_ostringstream(ios_base::openmode __wch = ios_base::out) - : basic_ostream<_CharT, _Traits>(&__sb_), - __sb_(__wch | ios_base::out) {} -#endif + : basic_ostream<_CharT, _Traits>(&__sb_), __sb_(__wch | ios_base::out) {} _LIBCPP_INLINE_VISIBILITY explicit basic_ostringstream(const string_type& __s, @@ -816,19 +798,13 @@ private: public: // 30.8.5.1 [stringstream.cons], constructors -#ifndef _LIBCPP_CXX03_LANG _LIBCPP_INLINE_VISIBILITY - basic_stringstream() : basic_stringstream(ios_base::in | ios_base::out) {} + basic_stringstream() + : basic_iostream<_CharT, _Traits>(&__sb_), __sb_(ios_base::in | ios_base::out) {} _LIBCPP_INLINE_VISIBILITY explicit basic_stringstream(ios_base::openmode __wch) : basic_iostream<_CharT, _Traits>(&__sb_), __sb_(__wch) {} -#else - _LIBCPP_INLINE_VISIBILITY - explicit basic_stringstream(ios_base::openmode __wch = ios_base::in | - ios_base::out) - : basic_iostream<_CharT, _Traits>(&__sb_), __sb_(__wch) {} -#endif _LIBCPP_INLINE_VISIBILITY explicit basic_stringstream(const string_type& __s, diff --git a/libcxx/include/string b/libcxx/include/string index c5e0745..3917c07 100644 --- a/libcxx/include/string +++ b/libcxx/include/string @@ -4439,8 +4439,6 @@ basic_istream<_CharT, _Traits>& getline(basic_istream<_CharT, _Traits>& __is, basic_string<_CharT, _Traits, _Allocator>& __str); -#ifndef _LIBCPP_CXX03_LANG - template inline _LIBCPP_INLINE_VISIBILITY basic_istream<_CharT, _Traits>& @@ -4453,8 +4451,6 @@ basic_istream<_CharT, _Traits>& getline(basic_istream<_CharT, _Traits>&& __is, basic_string<_CharT, _Traits, _Allocator>& __str); -#endif // _LIBCPP_CXX03_LANG - #if _LIBCPP_STD_VER > 17 template inline _LIBCPP_INLINE_VISIBILITY diff --git a/libcxx/test/std/input.output/file.streams/fstreams/filebuf.assign/move_assign.pass.cpp b/libcxx/test/std/input.output/file.streams/fstreams/filebuf.assign/move_assign.pass.cpp index 69ccd20..173c9d1 100644 --- a/libcxx/test/std/input.output/file.streams/fstreams/filebuf.assign/move_assign.pass.cpp +++ b/libcxx/test/std/input.output/file.streams/fstreams/filebuf.assign/move_assign.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template > diff --git a/libcxx/test/std/input.output/file.streams/fstreams/filebuf.cons/move.pass.cpp b/libcxx/test/std/input.output/file.streams/fstreams/filebuf.cons/move.pass.cpp index 0a54167..38aba56 100644 --- a/libcxx/test/std/input.output/file.streams/fstreams/filebuf.cons/move.pass.cpp +++ b/libcxx/test/std/input.output/file.streams/fstreams/filebuf.cons/move.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template > @@ -31,7 +29,7 @@ int main(int, char**) assert(f.sputn("123", 3) == 3); f.pubseekoff(1, std::ios_base::beg); assert(f.sgetc() == '2'); - std::filebuf f2(move(f)); + std::filebuf f2(std::move(f)); assert(!f.is_open()); assert(f2.is_open()); assert(f2.sgetc() == '2'); @@ -45,7 +43,7 @@ int main(int, char**) assert(f.sputn(L"123", 3) == 3); f.pubseekoff(1, std::ios_base::beg); assert(f.sgetc() == L'2'); - std::wfilebuf f2(move(f)); + std::wfilebuf f2(std::move(f)); assert(!f.is_open()); assert(f2.is_open()); assert(f2.sgetc() == L'2'); diff --git a/libcxx/test/std/input.output/file.streams/fstreams/fstream.assign/move_assign.pass.cpp b/libcxx/test/std/input.output/file.streams/fstreams/fstream.assign/move_assign.pass.cpp index 6032b21..9bc7887 100644 --- a/libcxx/test/std/input.output/file.streams/fstreams/fstream.assign/move_assign.pass.cpp +++ b/libcxx/test/std/input.output/file.streams/fstreams/fstream.assign/move_assign.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template > diff --git a/libcxx/test/std/input.output/file.streams/fstreams/fstream.cons/move.pass.cpp b/libcxx/test/std/input.output/file.streams/fstreams/fstream.cons/move.pass.cpp index 9166737..e210b56 100644 --- a/libcxx/test/std/input.output/file.streams/fstreams/fstream.cons/move.pass.cpp +++ b/libcxx/test/std/input.output/file.streams/fstreams/fstream.cons/move.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template > @@ -26,7 +24,7 @@ int main(int, char**) { std::fstream fso(temp, std::ios_base::in | std::ios_base::out | std::ios_base::trunc); - std::fstream fs = move(fso); + std::fstream fs = std::move(fso); double x = 0; fs << 3.25; fs.seekg(0); @@ -37,7 +35,7 @@ int main(int, char**) { std::wfstream fso(temp, std::ios_base::in | std::ios_base::out | std::ios_base::trunc); - std::wfstream fs = move(fso); + std::wfstream fs = std::move(fso); double x = 0; fs << 3.25; fs.seekg(0); diff --git a/libcxx/test/std/input.output/file.streams/fstreams/ifstream.assign/move_assign.pass.cpp b/libcxx/test/std/input.output/file.streams/fstreams/ifstream.assign/move_assign.pass.cpp index b9df311..439db87 100644 --- a/libcxx/test/std/input.output/file.streams/fstreams/ifstream.assign/move_assign.pass.cpp +++ b/libcxx/test/std/input.output/file.streams/fstreams/ifstream.assign/move_assign.pass.cpp @@ -6,7 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 // FILE_DEPENDENCIES: test.dat // diff --git a/libcxx/test/std/input.output/file.streams/fstreams/ifstream.cons/move.pass.cpp b/libcxx/test/std/input.output/file.streams/fstreams/ifstream.cons/move.pass.cpp index 03475e1..28f55f6 100644 --- a/libcxx/test/std/input.output/file.streams/fstreams/ifstream.cons/move.pass.cpp +++ b/libcxx/test/std/input.output/file.streams/fstreams/ifstream.cons/move.pass.cpp @@ -6,7 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 // FILE_DEPENDENCIES: test.dat // @@ -25,14 +24,14 @@ int main(int, char**) { { std::ifstream fso("test.dat"); - std::ifstream fs = move(fso); + std::ifstream fs = std::move(fso); double x = 0; fs >> x; assert(x == 3.25); } { std::wifstream fso("test.dat"); - std::wifstream fs = move(fso); + std::wifstream fs = std::move(fso); double x = 0; fs >> x; assert(x == 3.25); diff --git a/libcxx/test/std/input.output/file.streams/fstreams/ofstream.assign/move_assign.pass.cpp b/libcxx/test/std/input.output/file.streams/fstreams/ofstream.assign/move_assign.pass.cpp index 720bcf0..4db1e6c 100644 --- a/libcxx/test/std/input.output/file.streams/fstreams/ofstream.assign/move_assign.pass.cpp +++ b/libcxx/test/std/input.output/file.streams/fstreams/ofstream.assign/move_assign.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template > diff --git a/libcxx/test/std/input.output/file.streams/fstreams/ofstream.cons/move.pass.cpp b/libcxx/test/std/input.output/file.streams/fstreams/ofstream.cons/move.pass.cpp index 60fbf2b..01676f0 100644 --- a/libcxx/test/std/input.output/file.streams/fstreams/ofstream.cons/move.pass.cpp +++ b/libcxx/test/std/input.output/file.streams/fstreams/ofstream.cons/move.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template > @@ -25,7 +23,7 @@ int main(int, char**) std::string temp = get_temp_file_name(); { std::ofstream fso(temp.c_str()); - std::ofstream fs = move(fso); + std::ofstream fs = std::move(fso); fs << 3.25; } { @@ -37,7 +35,7 @@ int main(int, char**) std::remove(temp.c_str()); { std::wofstream fso(temp.c_str()); - std::wofstream fs = move(fso); + std::wofstream fs = std::move(fso); fs << 3.25; } { diff --git a/libcxx/test/std/input.output/iostream.format/input.streams/iostreamclass/iostream.assign/move_assign.pass.cpp b/libcxx/test/std/input.output/iostream.format/input.streams/iostreamclass/iostream.assign/move_assign.pass.cpp index 7b02842..fb1f524 100644 --- a/libcxx/test/std/input.output/iostream.format/input.streams/iostreamclass/iostream.assign/move_assign.pass.cpp +++ b/libcxx/test/std/input.output/iostream.format/input.streams/iostreamclass/iostream.assign/move_assign.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template > diff --git a/libcxx/test/std/input.output/iostream.format/input.streams/iostreamclass/iostream.cons/move.pass.cpp b/libcxx/test/std/input.output/iostream.format/input.streams/iostreamclass/iostream.cons/move.pass.cpp index 514cde0..2a4e1a6 100644 --- a/libcxx/test/std/input.output/iostream.format/input.streams/iostreamclass/iostream.cons/move.pass.cpp +++ b/libcxx/test/std/input.output/iostream.format/input.streams/iostreamclass/iostream.cons/move.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template > diff --git a/libcxx/test/std/input.output/iostream.format/input.streams/istream/istream.assign/move_assign.pass.cpp b/libcxx/test/std/input.output/iostream.format/input.streams/istream/istream.assign/move_assign.pass.cpp index bd90117..7899c63 100644 --- a/libcxx/test/std/input.output/iostream.format/input.streams/istream/istream.assign/move_assign.pass.cpp +++ b/libcxx/test/std/input.output/iostream.format/input.streams/istream/istream.assign/move_assign.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template > diff --git a/libcxx/test/std/input.output/iostream.format/input.streams/istream/istream.cons/copy.fail.cpp b/libcxx/test/std/input.output/iostream.format/input.streams/istream/istream.cons/copy.fail.cpp index c5f10fa..90e5315 100644 --- a/libcxx/test/std/input.output/iostream.format/input.streams/istream/istream.cons/copy.fail.cpp +++ b/libcxx/test/std/input.output/iostream.format/input.streams/istream/istream.cons/copy.fail.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template > @@ -47,10 +45,7 @@ struct test_istream }; - int main(int, char**) { - - return 0; } diff --git a/libcxx/test/std/input.output/iostream.format/input.streams/istream/istream.cons/move.pass.cpp b/libcxx/test/std/input.output/iostream.format/input.streams/istream/istream.cons/move.pass.cpp index 2216315..fb071ba 100644 --- a/libcxx/test/std/input.output/iostream.format/input.streams/istream/istream.cons/move.pass.cpp +++ b/libcxx/test/std/input.output/iostream.format/input.streams/istream/istream.cons/move.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template > diff --git a/libcxx/test/std/input.output/iostream.format/output.streams/ostream.assign/move_assign.pass.cpp b/libcxx/test/std/input.output/iostream.format/output.streams/ostream.assign/move_assign.pass.cpp index b529970..8fcb0c2 100644 --- a/libcxx/test/std/input.output/iostream.format/output.streams/ostream.assign/move_assign.pass.cpp +++ b/libcxx/test/std/input.output/iostream.format/output.streams/ostream.assign/move_assign.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template > diff --git a/libcxx/test/std/input.output/iostream.format/output.streams/ostream.cons/move.pass.cpp b/libcxx/test/std/input.output/iostream.format/output.streams/ostream.cons/move.pass.cpp index 345388b..73991b3 100644 --- a/libcxx/test/std/input.output/iostream.format/output.streams/ostream.cons/move.pass.cpp +++ b/libcxx/test/std/input.output/iostream.format/output.streams/ostream.cons/move.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template > diff --git a/libcxx/test/std/input.output/iostreams.base/is_error_code_enum_io_errc.pass.cpp b/libcxx/test/std/input.output/iostreams.base/is_error_code_enum_io_errc.pass.cpp index 76eb831..13f90d9 100644 --- a/libcxx/test/std/input.output/iostreams.base/is_error_code_enum_io_errc.pass.cpp +++ b/libcxx/test/std/input.output/iostreams.base/is_error_code_enum_io_errc.pass.cpp @@ -5,8 +5,6 @@ // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===----------------------------------------------------------------------===// -// -// UNSUPPORTED: c++03 // diff --git a/libcxx/test/std/input.output/string.streams/istringstream/istringstream.assign/move.pass.cpp b/libcxx/test/std/input.output/string.streams/istringstream/istringstream.assign/move.pass.cpp index c9b7013..93c8313 100644 --- a/libcxx/test/std/input.output/string.streams/istringstream/istringstream.assign/move.pass.cpp +++ b/libcxx/test/std/input.output/string.streams/istringstream/istringstream.assign/move.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template , class Allocator = allocator > diff --git a/libcxx/test/std/input.output/string.streams/istringstream/istringstream.cons/move.pass.cpp b/libcxx/test/std/input.output/string.streams/istringstream/istringstream.cons/move.pass.cpp index e4f1f2b..650284d 100644 --- a/libcxx/test/std/input.output/string.streams/istringstream/istringstream.cons/move.pass.cpp +++ b/libcxx/test/std/input.output/string.streams/istringstream/istringstream.cons/move.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template , class Allocator = allocator > diff --git a/libcxx/test/std/input.output/string.streams/ostringstream/ostringstream.assign/move.pass.cpp b/libcxx/test/std/input.output/string.streams/ostringstream/ostringstream.assign/move.pass.cpp index 52e4ace..8be3a43 100644 --- a/libcxx/test/std/input.output/string.streams/ostringstream/ostringstream.assign/move.pass.cpp +++ b/libcxx/test/std/input.output/string.streams/ostringstream/ostringstream.assign/move.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template , class Allocator = allocator > diff --git a/libcxx/test/std/input.output/string.streams/ostringstream/ostringstream.cons/move.pass.cpp b/libcxx/test/std/input.output/string.streams/ostringstream/ostringstream.cons/move.pass.cpp index 3a3f42f..6823bb6 100644 --- a/libcxx/test/std/input.output/string.streams/ostringstream/ostringstream.cons/move.pass.cpp +++ b/libcxx/test/std/input.output/string.streams/ostringstream/ostringstream.cons/move.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template , class Allocator = allocator > diff --git a/libcxx/test/std/input.output/string.streams/stringbuf/stringbuf.cons/move.pass.cpp b/libcxx/test/std/input.output/string.streams/stringbuf/stringbuf.cons/move.pass.cpp index 9fb588d..af1eb38 100644 --- a/libcxx/test/std/input.output/string.streams/stringbuf/stringbuf.cons/move.pass.cpp +++ b/libcxx/test/std/input.output/string.streams/stringbuf/stringbuf.cons/move.pass.cpp @@ -22,32 +22,32 @@ int main(int, char**) { { std::stringbuf buf1("testing"); - std::stringbuf buf(move(buf1)); + std::stringbuf buf(std::move(buf1)); assert(buf.str() == "testing"); } { std::stringbuf buf1("testing", std::ios_base::in); - std::stringbuf buf(move(buf1)); + std::stringbuf buf(std::move(buf1)); assert(buf.str() == "testing"); } { std::stringbuf buf1("testing", std::ios_base::out); - std::stringbuf buf(move(buf1)); + std::stringbuf buf(std::move(buf1)); assert(buf.str() == "testing"); } { std::wstringbuf buf1(L"testing"); - std::wstringbuf buf(move(buf1)); + std::wstringbuf buf(std::move(buf1)); assert(buf.str() == L"testing"); } { std::wstringbuf buf1(L"testing", std::ios_base::in); - std::wstringbuf buf(move(buf1)); + std::wstringbuf buf(std::move(buf1)); assert(buf.str() == L"testing"); } { std::wstringbuf buf1(L"testing", std::ios_base::out); - std::wstringbuf buf(move(buf1)); + std::wstringbuf buf(std::move(buf1)); assert(buf.str() == L"testing"); } diff --git a/libcxx/test/std/input.output/string.streams/stringstream.cons/move.pass.cpp b/libcxx/test/std/input.output/string.streams/stringstream.cons/move.pass.cpp index 71c385a..642fd75 100644 --- a/libcxx/test/std/input.output/string.streams/stringstream.cons/move.pass.cpp +++ b/libcxx/test/std/input.output/string.streams/stringstream.cons/move.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template , class Allocator = allocator > diff --git a/libcxx/test/std/input.output/string.streams/stringstream.cons/stringstream.assign/move.pass.cpp b/libcxx/test/std/input.output/string.streams/stringstream.cons/stringstream.assign/move.pass.cpp index e2a7506..91a685d 100644 --- a/libcxx/test/std/input.output/string.streams/stringstream.cons/stringstream.assign/move.pass.cpp +++ b/libcxx/test/std/input.output/string.streams/stringstream.cons/stringstream.assign/move.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template , class Allocator = allocator > diff --git a/libcxx/test/std/strings/basic.string/string.nonmembers/string.io/get_line_delim_rv.pass.cpp b/libcxx/test/std/strings/basic.string/string.nonmembers/string.io/get_line_delim_rv.pass.cpp index af2e62a..d2e5ab5 100644 --- a/libcxx/test/std/strings/basic.string/string.nonmembers/string.io/get_line_delim_rv.pass.cpp +++ b/libcxx/test/std/strings/basic.string/string.nonmembers/string.io/get_line_delim_rv.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template @@ -35,13 +33,13 @@ int main(int, char**) assert(s == L" abc"); } { - typedef std::basic_string, min_allocator> S; + typedef std::basic_string, min_allocator > S; S s("initial text"); getline(std::istringstream(" abc* def* ghij"), s, '*'); assert(s == " abc"); } { - typedef std::basic_string, min_allocator> S; + typedef std::basic_string, min_allocator > S; S s(L"initial text"); getline(std::wistringstream(L" abc* def* ghij"), s, L'*'); assert(s == L" abc"); diff --git a/libcxx/test/std/strings/basic.string/string.nonmembers/string.io/get_line_rv.pass.cpp b/libcxx/test/std/strings/basic.string/string.nonmembers/string.io/get_line_rv.pass.cpp index 322b49b..3fb35cc 100644 --- a/libcxx/test/std/strings/basic.string/string.nonmembers/string.io/get_line_rv.pass.cpp +++ b/libcxx/test/std/strings/basic.string/string.nonmembers/string.io/get_line_rv.pass.cpp @@ -6,8 +6,6 @@ // //===----------------------------------------------------------------------===// -// UNSUPPORTED: c++03 - // // template @@ -35,13 +33,13 @@ int main(int, char**) assert(s == L" abc"); } { - typedef std::basic_string, min_allocator> S; + typedef std::basic_string, min_allocator > S; S s("initial text"); getline(std::istringstream(" abc\n def\n ghij"), s); assert(s == " abc"); } { - typedef std::basic_string, min_allocator> S; + typedef std::basic_string, min_allocator > S; S s(L"initial text"); getline(std::wistringstream(L" abc\n def\n ghij"), s); assert(s == L" abc"); -- 2.7.4