summaryrefslogtreecommitdiffstats
path: root/libcxx/test
Commit message (Collapse)AuthorAgeFilesLines
...
* Renamed some of the newly added tests. No functional changeMarshall Clow2017-06-156-0/+0
| | | | llvm-svn: 305453
* Fix another test with modules enabledEric Fiselier2017-06-151-0/+1
| | | | llvm-svn: 305448
* Fix test when modules are enabledEric Fiselier2017-06-151-0/+1
| | | | llvm-svn: 305445
* Add some const_casts in places where we were implicitly casting away ↵Marshall Clow2017-06-141-1/+1
| | | | | | constness. No functional change, but now they're explicit llvm-svn: 305410
* Mark `__is_inplace_*` tests as UNSUPPORTED in <= C++14.Michael Park2017-06-142-0/+4
| | | | llvm-svn: 305373
* Add an `__is_inplace_index` metafunction.Michael Park2017-06-142-0/+64
| | | | | | | | | | | | Summary: This is used to constrain `variant`'s converting constructor correctly. Reviewers: EricWF, mclow.lists Reviewed By: EricWF, mclow.lists Differential Revision: https://reviews.llvm.org/D34111 llvm-svn: 305370
* Implement the non-parallel versions of reduce and transform_reduce for C++17Marshall Clow2017-06-146-0/+520
| | | | llvm-svn: 305365
* Fix bug 33389 - __is_transparent check requires too muchMarshall Clow2017-06-1311-13/+73
| | | | llvm-svn: 305292
* Add a test with an empty input range - should do nothingMarshall Clow2017-06-131-0/+6
| | | | llvm-svn: 305268
* Mark the recent variant test as UNSUPPORTED for C++ before 17Marshall Clow2017-06-121-1/+3
| | | | llvm-svn: 305198
* Make tuple_element static_assert in pair if the index is out of range. Also, ↵Marshall Clow2017-06-122-0/+59
| | | | | | add a message to variant_alternative<> in the similar case (it already asserted). Add tests for this llvm-svn: 305196
* [array.tuple]/1 says that instantiating tuple_element<N, array<T, M>> is ↵Marshall Clow2017-06-121-0/+35
| | | | | | ill-formed if N >= M. We didn't do that. Add a static_assert to cause a failure, and a test that checks that we failed llvm-svn: 305191
* Implement the non-parallel versions of exclusive_scan and ↵Marshall Clow2017-06-103-0/+338
| | | | | | transform_exclusive_scan. Reviewed as https://reviews.llvm.org/D34038. llvm-svn: 305136
* [libcxx] [test] Update locale names for Windows.Stephan T. Lavavej2017-06-083-15/+15
| | | | | | | | | | | | | | | | | locale.codecvt.byname/ctor_char.pass.cpp: This test used to use "en_US" as a plain string instead of using platform_support. Need to fix this because MS STL expects "en-US" instead. platform_support.h: These are the legacy Windows locale names. Should use IETF tags instead. I've also added en_US, since a test was using that as a locale string as well. msvc_stdlib_force_include.hpp: Remove _MSVC_STL_VER. The libraries will directly define _MSVC_STL_VERSION in the future. Fixes D29351. llvm-svn: 305000
* [libcxx] [test] Remove a Clang/C2 workaround.Stephan T. Lavavej2017-06-081-2/+0
| | | | | | | | Clang/LLVM doesn't need this workaround. Fixes D33955. llvm-svn: 304999
* XFAIL tuple deduction guide test on GCCEric Fiselier2017-06-081-0/+5
| | | | llvm-svn: 304969
* Add tests for class template deduction on std::tuple.Eric Fiselier2017-06-081-0/+150
| | | | llvm-svn: 304967
* Fix compile error with Bionic's PTHREAD_MUTEX_INITIALIZEREric Fiselier2017-06-071-0/+2
| | | | | | | | | | | | | | | | | | | | | | On Bionic PTHREAD_MUTEX_INITIALIZER contains the expression "<enum-type> & <integer-type>", which causes ADL to perform name lookup for operator&. During this lookup Clang decides that it requires the default member initializer for std::mutex while defining the DMI for std::mutex::__m_. If I'm not mistaken this is caused by the explicit noexcept declaration on the defaulted constructor. This patch removes the explicit noexcept and instead allows the compiler to declare the default constructor implicitly noexcept. It also adds a static_assert to ensure that happens. Unfortunatly because it's not easy to change the value of _LIBCPP_MUTEX_INITIALIZER for a single test there is no good way to test this patch. The Clang behavior causing the trouble here was introduced in r287713, which first appears in the 4.0 release. llvm-svn: 304942
* Implement LWG 2904.Michael Park2017-06-073-63/+0
| | | | | | | | | | | | | | | | | | | Summary: - Removed the move-constructibe requirement from copy-assignable. - Updated `__assign_alt` such that we direct initialize if `_Tp` can be `nothrow`-constructible from `_Arg`, or `_Tp`'s move construction can throw. Otherwise, construct a temporary and move it. - Updated the tests to remove the pre-LWG2904 path. Depends on D32671. Reviewers: EricWF, CaseyCarter Reviewed By: EricWF Differential Revision: https://reviews.llvm.org/D33965 llvm-svn: 304891
* Fix test with exceptions disabledEric Fiselier2017-06-071-29/+30
| | | | llvm-svn: 304883
* [test] Test changes to accommodate LWG 2904 "Make variant move-assignment ↵Casey Carter2017-06-0710-719/+714
| | | | | | | | | | more exception safe" Also: Move constexpr / triviality extension tests into the std tree and make them conditional on _LIBCPP_VERSION / _MSVC_STL_VERSION. https://reviews.llvm.org/D32671 llvm-svn: 304847
* add missing constexpr to optional::value_orCasey Carter2017-06-061-7/+13
| | | | | | | | [Credit to cpplearner] Differential Revision: https://reviews.llvm.org/D27850 llvm-svn: 304813
* [libcxx] [test] Add _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to ↵Stephan T. Lavavej2017-06-061-0/+3
| | | | | | | | | msvc_stdlib_force_include.hpp. This macro will instruct MSVC's STL to not warn about features that are deprecated in C++17, as libcxx tests those features and uses them elsewhere. llvm-svn: 304765
* [test] Remove workaround for C1XX empty parameter pack bugCasey Carter2017-06-053-57/+0
| | | | | | Was VSO#109062. This bug was filed *4 years ago*. I submitted a workaround to enable the scoped_allocator_adaptor tests to pass. Bug fixed a week and a half later. This was either a waste of my time, or I've discovered that libc++ has magical bugfix-inducing powers. My money's on the latter. llvm-svn: 304730
* Fix the recently introduced test to work on C++03Marshall Clow2017-06-031-5/+13
| | | | llvm-svn: 304629
* Fix some undefined behavior in __hash_table. Thanks to vsk for the report ↵Marshall Clow2017-06-031-0/+80
| | | | | | and the patch. Reviewed as https://reviews.llvm.org/D33588. llvm-svn: 304617
* Mark two coroutine tests as unsupported under ubsan, againVedant Kumar2017-06-022-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit r304580, making bool_await_suspend.pass.cpp and generator.pass.cpp unsupported on ubsan again. The host compiler is based on r304329, which has the change from PR33271 (r304277). However, this was not enough to address the issue. Bot Failure: http://lab.llvm.org:8011/builders/libcxx-libcxxabi-x86_64-linux-ubuntu-ubsan/builds/628 Unknown type! UNREACHABLE executed at /home/eric/full-llvm/llvm/lib/IR/ValueTypes.cpp:287! llvm::EVT::getEVT(llvm::Type*, bool) (/usr/local/bin/clang-5.0+0x17e7a07) llvm::TargetLoweringBase::getValueType(llvm::DataLayout const&, llvm::Type*, bool) const (/usr/local/bin/clang-5.0+0x852c4a) llvm::ComputeValueVTs(llvm::TargetLowering const&, llvm::DataLayout const&, llvm::Type*, llvm::SmallVectorImpl<llvm::EVT>&, llvm::SmallVectorImpl<unsigned long>*, unsigned long) (/usr/local/bin/clang-5.0+0x141b6e9) llvm::SelectionDAGBuilder::visitTargetIntrinsic(llvm::CallInst const&, unsigned int) (/usr/local/bin/clang-5.0+0x237b1ca) clang-5.0: /home/eric/full-llvm/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp:1236: virtual void llvm::DwarfDebug::endFunctionImpl(const llvm::MachineFunction *): Assertion `LScopes.getAbstractScopesList().size() == NumAbstractScopes && "ensureAbstractVariableIsCreated inserted abstract scopes"' failed. __assert_fail_base /build/glibc-9tT8Do/glibc-2.23/assert/assert.c:92:0 (/lib/x86_64-linux-gnu/libc.so.6+0x2dc82) llvm::DwarfDebug::endFunctionImpl(llvm::MachineFunction const*) (/usr/local/bin/clang-5.0+0x223f86b) llvm::DebugHandlerBase::endFunction(llvm::MachineFunction const*) (/usr/local/bin/clang-5.0+0x227a5a1) llvm::AsmPrinter::EmitFunctionBody() (/usr/local/bin/clang-5.0+0x222522f) llvm-svn: 304591
* Revert "Mark two coroutine tests as unsupported under ubsan"Vedant Kumar2017-06-022-6/+0
| | | | | | | This reverts commit r304462, thereby re-enabling two tests under ubsan. We expect these tests to pass now that PR33271 is fixed. llvm-svn: 304580
* [test] Allow non-libc++ coroutine_handle::done to strengthen noexceptCasey Carter2017-06-014-6/+6
| | | | llvm-svn: 304487
* Mark two coroutine tests as unsupported under ubsanVedant Kumar2017-06-012-0/+6
| | | | | | | | | They appear to crash inside of SelectionDAG on some Linux bots, when ubsan is enabled. https://bugs.llvm.org/show_bug.cgi?id=33271 llvm-svn: 304462
* Remove ubsan XFAILS in two testsVedant Kumar2017-06-012-6/+0
| | | | | | | These two tests are ubsan-clean now: http://lab.llvm.org:8080/green/job/clang-stage2-cmake-RgSan_check/3553/ llvm-svn: 304450
* Fix name used in -verify diagnostic to match trunkEric Fiselier2017-06-011-2/+2
| | | | llvm-svn: 304384
* Fix silly mistakes in recent changes made to coroutine testEric Fiselier2017-05-311-4/+2
| | | | llvm-svn: 304364
* [Libc++] Use #pragma push_macro/pop_macro to better handle min/max on WindowsEric Fiselier2017-05-311-0/+298
| | | | | | | | | | | | | | | | Summary: This patch improves how libc++ handles min/max macros within the headers. Previously libc++ would undef them and emit a warning. This patch changes libc++ to use `#pragma push_macro` to save the macro before undefining it, and `#pragma pop_macro` to restore the macros and the end of the header. Reviewers: mclow.lists, bcraig, compnerd, EricWF Reviewed By: EricWF Subscribers: cfe-commits, krytarowski Differential Revision: https://reviews.llvm.org/D33080 llvm-svn: 304357
* Guard against more macros in tchar.hEric Fiselier2017-05-311-1/+7
| | | | llvm-svn: 304352
* Transform the libc++ coroutine shell tests into normal .pass.cpp tests.Eric Fiselier2017-05-3125-107/+15
| | | | | | | | | The shell test versions didn't get all of the flags normal tests do, specifically warning flags. This patch makes them .pass.cpp tests, and uses a lit.local.cfg to add -fcoroutines-ts and to make them UNSUPPORTED when that flag isn't available. llvm-svn: 304351
* Remove uses of _UI because Windows is evil and tchar.h #define's itEric Fiselier2017-05-311-0/+2
| | | | llvm-svn: 304348
* [test] s/uexpectedly/unexpectedly/Casey Carter2017-05-301-1/+1
| | | | llvm-svn: 304236
* [coroutines] Make coroutine_handle<T>::from_address ill-formed for ↵Eric Fiselier2017-05-292-0/+55
| | | | | | | | | | | | | everything but void*. from_address requires that the provided pointer refer to the suspended coroutine, which doesn't have a type, or at least not one knowable by the user. Therefore every use of `from_address` with a typed pointer is almost certainly a bug. This behavior is a part of the TS specification, but hopefully it will be in the future. llvm-svn: 304172
* Fix coroutine test failures caused by API misusages.Eric Fiselier2017-05-293-6/+6
| | | | | | | | More tests to come. I think that from_address overload should be deleted or ill-formed, except for the 'void*' one; The user cannot possibly have a typed pointer to the coroutine state. llvm-svn: 304131
* Fix multiple bugs in coroutine tests.Eric Fiselier2017-05-291-4/+6
| | | | llvm-svn: 304124
* Correct XFAIL's in coroutine tests to only list ubsanEric Fiselier2017-05-282-9/+10
| | | | llvm-svn: 304106
* Fix use of uninitialized memoryEric Fiselier2017-05-281-1/+1
| | | | llvm-svn: 304105
* XFAIL tests which trigger coroutine debug info crash in ClangEric Fiselier2017-05-282-0/+8
| | | | llvm-svn: 304104
* Add hack to allow test to run w/o C++17 copy elisionEric Fiselier2017-05-281-2/+9
| | | | llvm-svn: 304103
* Remove XFAIL's for recently fixed bugEric Fiselier2017-05-281-4/+0
| | | | llvm-svn: 304102
* [coroutines] Add end-to-end tests within libc++Eric Fiselier2017-05-289-0/+884
| | | | | | | | | | | | | This patch adds end-to-end/breathing tests for coroutines into libc++. The tests aren't specifically to test libc++ requirements but instead are intented to ensure coroutines are working fine in general. Although libc++ isn't exactly the most correct place for these tests to live, there is one major advantage. The libc++ test suite is also used by MSVC and by adding the tests here it ensures they will be run against all currently available coroutine implementations. llvm-svn: 304101
* Workaround debug info bug in Clangs coroutine implementationEric Fiselier2017-05-261-0/+4
| | | | llvm-svn: 303966
* Get <experimental/coroutine> working in C++03.Eric Fiselier2017-05-261-0/+57
| | | | | | | | | | | | | Clang supports coroutines in all dialects; Therefore libc++ should too, otherwise the Clang extension is unusable. I'm not convinced extending support to C++03 is a feasible long term plan, since as the library grows to offer things like generators it will be come increasingly difficult to limit the implementation to C++03. However for the time being supporting C++03 isn't a big deal. llvm-svn: 303963
* Remove incorrect #ifdef guards around variant tests.Eric Fiselier2017-05-262-4/+2
| | | | | | | | | | | The tests were previously guarded by #if defined(_LIBCPP_VER) || defined(_MSVC_STL_VER), which is both incorrect (e.g. _LIBCPP_VERSION) and unneeded. Although the tests are technically non-standard (yet) they are supported by both libc++ and MSVC's STL. libstdc++ doesn't regularly use the test suite so I'm not concerned about guarding these tests for them. llvm-svn: 303953
OpenPOWER on IntegriCloud