summaryrefslogtreecommitdiffstats
path: root/libcxx
Commit message (Collapse)AuthorAgeFilesLines
...
* Allow to set locale on Windows.Martin Storsjo2017-11-234-19/+96
| | | | | | | | | | | | | | | Fix the problem PR31516 with setting locale on Windows by wrapping _locale_t with a pointer-like class. Reduces 74 test failures in std/localization test suite to 47 test failures (on llvm clang, Visual Studio 2015). Number of test failures doesn't depend on the platform (x86 or x64). Patch by Andrey Khalyavin. Differential Revision: https://reviews.llvm.org/D40181 llvm-svn: 318902
* Add additional 'UNSUPPORTED' to the test case.Marshall Clow2017-11-231-1/+2
| | | | llvm-svn: 318897
* Add [[nodiscard]] to std::async as part of P0600.Marshall Clow2017-11-233-2/+40
| | | | llvm-svn: 318889
* [libcxx] Implement std::to_address for C++20Eric Fiselier2017-11-222-1/+160
| | | | | | | | | | | | | | Summary: Now implements P0653R2 - Utility to convert to raw pointer. Reviewers: mclow.lists, EricWF Reviewed By: EricWF Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D35470 llvm-svn: 318865
* Implement p0137r1 - std::launder. Reviewed as https://reviews.llvm.org/D40144Marshall Clow2017-11-226-0/+130
| | | | llvm-svn: 318864
* [libcxx][fixup] Mark std::basic_istream::getline tests as failing for ↵Volodymyr Sapsai2017-11-222-0/+16
| | | | | | | | | previous libcxx versions. r318862 added a fix for 0-termination input array in case of an error. Previous libcxx versions don't have the fix and corresponding tests should be failing. llvm-svn: 318863
* [libcxx] Make std::basic_istream::getline 0-terminate input array in case of ↵Volodymyr Sapsai2017-11-223-2/+112
| | | | | | | | | | | | | error. It covers the cases when the sentry object returns false and when an exception was thrown. Corresponding standard paragraph is C++14 [istream.unformatted]p21: In any case, if n is greater than zero, it then stores a null character (using charT()) into the next successive location of the array. Patch by Reimar Döffinger. llvm-svn: 318862
* Add another test_macros.h include I missed to tuple.by.type.pass.cppBilly Robert O'Neal III2017-11-221-0/+1
| | | | llvm-svn: 318830
* Add some tests for operations on const associative containers. Part of LWG#2542Marshall Clow2017-11-226-9/+32
| | | | llvm-svn: 318818
* Replace assert(true) in tests with actual asserts. Reviewed as ↵Billy Robert O'Neal III2017-11-211-2/+2
| | | | | | | | | | | | | | https://reviews.llvm.org/D40324 In a17cd7c641c34b6c4bd4845a4d4fb590cb6c238c Marshall added assert(true) to the vector<bool>::size tests, which break on C1XX: D:\Contest\gl0qojfu.5pe\src\qa\vc\libs\libcxx\upstream\test\std\containers\sequences\vector.bool\size.pass.cpp(62): error C2220: warning treated as error - no 'object' file generated d:\contest\gl0qojfu.5pe\src\qa\vc\libs\libcxx\upstream\test\std\containers\sequences\vector.bool\size.pass.cpp(33) : warning C6326: Potential comparison of a constant with another constant. d:\contest\gl0qojfu.5pe\src\qa\vc\libs\libcxx\upstream\test\std\containers\sequences\vector.bool\size.pass.cpp(52) : warning C6326: Potential comparison of a constant with another constant. The corresponding test for vector::size asserts assert(c.size() == 3);, so I changed it to do that here. llvm-svn: 318812
* Remove a broken win32 locale function redirectionMartin Storsjo2017-11-211-1/+0
| | | | | | | | | | | | | | | | One can't replace vsscanf(_l) with a sscanf(_l) that doesn't take a va_list. This has been untouched since it was added in SVN r140728, so apparently it hasn't been used since. One reason for this mistake originally might have been that there was no _vsscanf_l until MSVC 2015. Since it's unused, just remove this define. Differential Revision: https://reviews.llvm.org/D40323 llvm-svn: 318810
* Add missing test_macros.h inclusion.Billy Robert O'Neal III2017-11-211-0/+1
| | | | llvm-svn: 318808
* Change (void) casts to TEST_IGNORE_NODISCARD, as requested by Eric. Reviewed ↵Billy Robert O'Neal III2017-11-2165-96/+103
| | | | | | as https://reviews.llvm.org/D40065 llvm-svn: 318804
* Fix std::string::data() symbol during library build.Eric Fiselier2017-11-201-1/+1
| | | | | | | | | | | | | | The non-const data() member of std::string is only exposed in C++17 and beyond. However std::string is externally instantiated and so the member function needs to be exposed to be externally instantiated. On Linux and OS X this shouldn't cause a problem, because _LIBCPP_INLINE_VISIBILITY ensures the symbol is always inlined. However on Windows, the symbol gets marked dllimport, but there is no definition to import, causing link errors. llvm-svn: 318690
* Attempt to fix template depth test failures on older Clang versionsEric Fiselier2017-11-191-0/+3
| | | | llvm-svn: 318625
* Fix min/max usage in variantEric Fiselier2017-11-191-0/+5
| | | | llvm-svn: 318622
* [libc++] Shrink variant's index type when possibleEric Fiselier2017-11-193-8/+103
| | | | | | | | | | | | | | | | | | | Summary: Currently `std::variant` always uses an unsigned int to store the variant index. However this isn't nessesary and causes `std::variant` to be larger than it needs to be in most cases. This patch changes the index type to be `unsigned char` when possible, and `unsigned short` or `unsigned int` otherwise, depending on the size (Although it's questionable if it's even possible to create a variant with 65535 elements. Unfortunately this change is an ABI break, and as such is only enabled in ABI v2. Reviewers: mpark Reviewed By: mpark Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D40210 llvm-svn: 318621
* Fix nodiscard test when modules are enabledEric Fiselier2017-11-191-0/+1
| | | | llvm-svn: 318618
* Mark free functions size/empty/data conditionally noexcept.Marshall Clow2017-11-161-4/+31
| | | | llvm-svn: 318432
* More of P0600 - '[[nodiscard]] in the Library' mark empty() as nodiscard in ↵Marshall Clow2017-11-163-2/+32
| | | | | | filesystem::path llvm-svn: 318378
* More of P0600 - '[[nodiscard]] in the Library' mark empty() as nodiscard in ↵Marshall Clow2017-11-162-4/+31
| | | | | | match_results. <regex> llvm-svn: 318375
* More of P0600 - '[[nodiscard]] in the Library' mark empty() as nodiscard in ↵Marshall Clow2017-11-1510-420/+576
| | | | | | string, string_view, and the free function std::empty(). Removed tabs from <string_view>, which is why the diff is so big. llvm-svn: 318328
* [test] Alignment must be > __STDCPP_DEFAULT_NEW_ALIGNMENT__ to call aligned newCasey Carter2017-11-1510-10/+10
| | | | | | Differential Revision: D39221 llvm-svn: 318325
* Clean up the tests for free data(), size() and empty()Marshall Clow2017-11-153-24/+28
| | | | llvm-svn: 318313
* Tolerate even more [[nodiscard]] in the STL. Reviewed as ↵Billy Robert O'Neal III2017-11-1535-100/+104
| | | | | | https://reviews.llvm.org/D39080 llvm-svn: 318277
* Tolerate [[nodiscard]] annotations in the STL. Reviewed as ↵Billy Robert O'Neal III2017-11-1558-74/+98
| | | | | | https://reviews.llvm.org/D39033 llvm-svn: 318276
* First part of P0600 - '[[nodiscard] in the standard library'. Mark the ↵Marshall Clow2017-11-1528-17/+493
| | | | | | 'empty()' methods of all the containers as nodiscard. If you're calling empty() w/o looking at the result, you probably meanto to call 'clear()'. c++2a only llvm-svn: 318269
* Still more missing tests - this time for the unordered containersMarshall Clow2017-11-158-0/+432
| | | | llvm-svn: 318268
* Named the macro wrong in the test.Marshall Clow2017-11-151-1/+1
| | | | llvm-svn: 318259
* More missing tests - array<>::size() and array<>::max_size()Marshall Clow2017-11-152-0/+72
| | | | llvm-svn: 318256
* Update Appveyor LLVM install link to be current and non-brokenEric Fiselier2017-11-151-1/+1
| | | | llvm-svn: 318247
* Added tests for xxx.size() and xxx.empty() for all the sequence containersMarshall Clow2017-11-159-0/+478
| | | | llvm-svn: 318244
* Add two new macros: _LIBCPP_NODISCARD_AFTER_CXX17 and ↵Marshall Clow2017-11-143-0/+63
| | | | | | _LIBCPP_CONSTEXPR_AFTER_CXX17, along with a way to turn off the NODISCARD one: _LIBCPP_DISABLE_NODISCARD_AFTER_CXX17. No one is using these yet, but we will be ... soon llvm-svn: 318208
* Rename identifiers named `__output`Alexander Richardson2017-11-145-51/+54
| | | | | | | | | | | | | | | | Summary: In the CHERI clang compiler __output and __input are keywords and therefore we can't compile libc++ with our compiler. Reviewers: mclow.lists, EricWF, theraven Reviewed By: EricWF Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D39537 llvm-svn: 318144
* Another test for LWG2952Marshall Clow2017-11-141-0/+28
| | | | llvm-svn: 318126
* Implement LWG2950: std::byte operations are misspecifiedMarshall Clow2017-11-143-16/+39
| | | | llvm-svn: 318125
* Implement LWG2952: iterator_traits should work for pointers to cv TMarshall Clow2017-11-143-12/+30
| | | | llvm-svn: 318119
* Put the status in the wrong columnMarshall Clow2017-11-131-1/+1
| | | | llvm-svn: 318012
* Implement P0550R2: Transformation Trait remove_cvrefMarshall Clow2017-11-133-1/+67
| | | | llvm-svn: 318011
* Two more papers from AlbuquerqueMarshall Clow2017-11-121-0/+2
| | | | llvm-svn: 318000
* Updated C++2a status page with new features/defects approved in Albuquerque.Marshall Clow2017-11-121-0/+42
| | | | llvm-svn: 317996
* Add _LIBCPP_INLINE_VISIBILITY to __compressed_pair_elem membersAlex Lorenz2017-11-091-6/+12
| | | | | | | | | | | | | | The commit r300140 changed the implementation of compressed_pair, but didn't add _LIBCPP_INLINE_VISIBILITY to the constructors and get members of the compressed_pair_elem class. This patch adds the visibility annotation. I didn't find a way to test this change with libc++ regression tests. rdar://35352579 Differential Revision: https://reviews.llvm.org/D39751 llvm-svn: 317816
* [libcxx] Mark test cxa_deleted_virtual.pass.cpp as failing for previous ↵Volodymyr Sapsai2017-11-081-0/+9
| | | | | | | | | | | | | | | | | | | | libcxx versions. r313500 added a fix for undefined "___cxa_deleted_virtual" symbol. Previous libcxx versions don't have the fix and corresponding test should be failing. rdar://problem/34521053 Reviewers: EricWF, mclow.lists, ahatanak Reviewed By: ahatanak Subscribers: mehdi_amini, cfe-commits Differential Revision: https://reviews.llvm.org/D39776 llvm-svn: 317734
* Added include for <cassert>Marshall Clow2017-11-081-0/+1
| | | | llvm-svn: 317722
* Teach test suite about C++2a dialect flag.Eric Fiselier2017-11-072-3/+4
| | | | | | | | This patch teaches the test suite configuration about the -std=c++2a flag. And, since it's the newest dialect, change the test suite to choose it, if possible, by default. llvm-svn: 317611
* Change test suite to support c++17 dialect flag instead of c++1z.Eric Fiselier2017-11-075-7/+9
| | | | | | | | This patch changes the test suite to attempt and prefer -std=c++17 over -std=c++1z. It also fixes the REQUIRES and UNSUPPORTED lit markers to refer to c++17 over c++1z. llvm-svn: 317610
* Change a bunch of comments from C++1z to C++17. NFCMarshall Clow2017-11-0217-17/+17
| | | | llvm-svn: 317212
* Mark tests as unsupported in C++98 as wellRoger Ferrer Ibanez2017-11-022-2/+2
| | | | | | Differential Revision: https://reviews.llvm.org/D38362 llvm-svn: 317210
* Mark Endian as 'in progress'Marshall Clow2017-11-021-1/+1
| | | | llvm-svn: 317209
* Revert "[libc++] Don't alias quick_exit if __ANDROID_API__ < 21"Dan Albert2017-11-011-5/+1
| | | | | | | | Broke the Darwin build bots. This reverts commit f56f1bba1ade4a408d403ff050d50e837bae47df. llvm-svn: 317142
OpenPOWER on IntegriCloud