summaryrefslogtreecommitdiffstats
path: root/libcxx/include/experimental
Commit message (Collapse)AuthorAgeFilesLines
* Fix initialzation order in dynarrayEric Fiselier2015-10-011-1/+1
| | | | llvm-svn: 248988
* Implementation of Boyer-Moore and Boyer-Moore-Horspool searchers for the LFTS.Marshall Clow2015-09-081-3/+324
| | | | llvm-svn: 247036
* Remove commented out TODOs. They defined unneeded methods.Eric Fiselier2015-08-191-3/+0
| | | | llvm-svn: 245411
* Make regex and any assert when they should throw an exception _but_ the user ↵Marshall Clow2015-08-171-1/+2
| | | | | | has decreed 'no exceptions'. This matches the behavior of string and vector llvm-svn: 245239
* Mark any as done and comment out extra methods until speaking to MarshallEric Fiselier2015-07-311-2/+3
| | | | llvm-svn: 243729
* [libcxx] Add <experimental/any> v2.Eric Fiselier2015-07-311-0/+591
| | | | | | | | | | | | | | | | Summary: This patch adds the second revision of <experimental/any>. I've been working from the LFTS draft found at this link. https://rawgit.com/cplusplus/fundamentals-ts/v1/fundamentals-ts.html#any Reviewers: danalbert, jroelofs, K-ballo, mclow.lists Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D6762 llvm-svn: 243728
* Implement the default searcher for std::experimental::search.Marshall Clow2015-07-201-0/+133
| | | | llvm-svn: 242682
* Implement the plugin-based version of std::search. There are no searchers ↵Marshall Clow2015-07-201-0/+6
| | | | | | yet; those are coming soon. llvm-svn: 242679
* Implement std::experimental::sample.Evgeniy Stepanov2015-05-131-0/+114
| | | | | | | Following specification in "C++ Extensions for Library Fundamentals": http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2015/n4480.html#alg.random.sample llvm-svn: 237264
* Fixed an 'extra tokens at end of #endif directive' warning in experimental/ratioMarshall Clow2015-04-231-1/+1
| | | | llvm-svn: 235607
* Remove constexpr support for std::apply because it introduces regressions.Eric Fiselier2015-04-191-1/+1
| | | | llvm-svn: 235274
* [libcxx] Add <experimental/tuple> header for LFTS.Eric Fiselier2015-03-171-0/+81
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This patch adds the `<experimental/tuple>` header (almost) as specified in the latest draft of the library fundamentals TS. The main changes in this patch are: 1. Added variable template `tuple_size_v` 2. Added function `apply(Func &&, Tuple &&)`. 3. Changed `__invoke` to be `_LIBCPP_CONSTEXPR_AFTER_CXX11`. The `apply(...)` implementation uses `__invoke` to invoke the given function. `__invoke` already provides the required functionality. Using `__invoke` also allows `apply` to be used on pointers to member function/objects as an extension. In order to facilitate this `__invoke` has to be marked `constexpr`. Test Plan: Each new feature was tested. The test cases for `tuple_size_v` are as follows: 1. tuple_size_v.pass.cpp - Check `tuple_size_v` on cv qualified tuples, pairs and arrays. 2. tuple_size_v.fail.cpp - Test on reference type. 3. tuple_size_v_2.fail.cpp - Test on non-tuple 4. tuple_size_v_3.fail.cpp - Test on pointer type. The test cases for tuple.apply are as follows: 1. arg_type.pass.cpp - Ensure that ref/pointer/cv qualified types are properly passed. 2. constexpr_types.pass.cpp - Ensure constexpr evaluation of apply is possible for `tuple` and `pair`. 3. extended_types.pass.cpp - Test apply on function types permitted by extension. 4. large_arity.pass.cpp - Test that apply can evaluated on tuples and arrays with large sizes. 5. ref_qualifiers.pass.cpp - Test that apply respects ref qualified functions. 6. return_type.pass.cpp - Test that apply returns the proper type. 7. types.pass.cpp - Test apply on function types as required by LFTS. Reviewers: mclow.lists Reviewed By: mclow.lists Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D4512 llvm-svn: 232515
* Define a new macro: _LIBCPP_HAS_NO_VARIABLE_TEMPLATES and use it. No ↵Marshall Clow2015-03-174-8/+8
| | | | | | functionality change. llvm-svn: 232493
* Change string_view::at to make it work with gcc and VC++. Thanks to K-ballo ↵Marshall Clow2015-02-231-4/+1
| | | | | | for the bug report, and Jonathan Wakeley for the code review in the bar. llvm-svn: 230260
* Enable testing with _LIBCPP_DEBUG and fix bad assertions in string_view.Eric Fiselier2015-02-181-2/+2
| | | | llvm-svn: 229698
* [libcxx] Add <experimental/ratio>Eric Fiselier2015-02-171-0/+77
| | | | | | | | | | | | | | | | | Summary: This patch is pretty simple. It just adds the _v traits from <ratio>. The draft can be found here. Reviewers: jroelofs, K-ballo, mclow.lists Reviewed By: mclow.lists Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D7351 llvm-svn: 229509
* Handle function name conflicts in _LIBCPP_MSVCRT modeSaleem Abdulrasool2015-02-131-0/+2
| | | | | | | | | | Visual Studio's SAL extension uses a macro named __deallocate. This macro is used pervasively, and gets included through various different ways. This conflicts with the similarly named interfaces in libc++. Introduce a undef header similar to __undef_min_max to handle this. This fixes a number of errors due to the macro replacing the function name. llvm-svn: 229162
* Move the test for zero-length into the char_traits (from string_view). Add ↵Marshall Clow2015-02-121-1/+1
| | | | | | tests to char_traits specializations llvm-svn: 228981
* Fixed a problem that UBSAN found, where we were calling memcmp(null, p, 0) - ↵Marshall Clow2015-02-121-1/+1
| | | | | | which is undefined behavior llvm-svn: 228952
* Add pragma system header to some experimental headers and add newlines to files.Eric Fiselier2015-02-105-2/+21
| | | | llvm-svn: 228712
* Fix more issues exposed by -pedantic-errors in c++03 modeEric Fiselier2015-02-102-2/+2
| | | | llvm-svn: 228711
* [libcxx] Add <experimental/system_error>Eric Fiselier2015-02-031-0/+59
| | | | | | | | | | | | | | | | | | Summary: This patch just adds the variable templates in <experimental/system_error>. see: https://rawgit.com/cplusplus/fundamentals-ts/v1/fundamentals-ts.html#syserror Reviewers: jroelofs, danalbert, K-ballo, mclow.lists Reviewed By: mclow.lists Subscribers: chandlerc, cfe-commits Differential Revision: http://reviews.llvm.org/D7353 llvm-svn: 227973
* [libcxx] Add <experimental/chrono>Eric Fiselier2015-02-022-0/+59
| | | | | | | | | | | | | | | | | Summary: This patch adds <experimental/chrono> which only contains a single variable template. See: https://rawgit.com/cplusplus/fundamentals-ts/v1/fundamentals-ts.html#time Reviewers: jroelofs, danalbert, K-ballo, mclow.lists Reviewed By: mclow.lists Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D7352 llvm-svn: 227860
* [libcxx] Add <experimental/type_traits> for LFTSEric Fiselier2014-12-191-0/+423
| | | | | | | | | | | | | | | | Summary: This adds the <experimental/type_traits> (minus invocation traits). Mostly just the `_v` traits. Reviewers: K-ballo, mclow.lists Reviewed By: mclow.lists Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D5742 llvm-svn: 224626
* Add all the relational operators to std::experimental::optional. Also update ↵Marshall Clow2014-12-091-120/+319
| | | | | | bad_optional_access to match the Library Fundamentals draft standard. This is not all of the upcoming changes to optional, though. llvm-svn: 223775
* Replaced checking in string_view::remove_suffix/remove_prefix by ↵Marshall Clow2014-11-111-4/+2
| | | | | | _LIBCPP_ASSERT, since this is technically undefined behavior. Fixes PR#21496 llvm-svn: 221717
* Mark string_view::to_string as const. Fixes PR21428Marshall Clow2014-11-021-1/+2
| | | | llvm-svn: 221101
* Change the comment on the closing #endif to match the condition on the ↵Marshall Clow2014-10-261-1/+1
| | | | | | corresponding #ifdef. Thanks to K-ballo for the catch. No functionality change. llvm-svn: 220647
* NFC. Move definition of _LIBCPP_ASSERT into __debug header and remove ↵Eric Fiselier2014-08-102-5/+3
| | | | | | | | | | | | | | | | | | external include guards. Things done in this patch: 1. Make __debug include __config since it uses macros from it. 2. The current method of defining _LIBCPP_ASSERT is prone to redefinitions. Move the null _LIBCPP_ASSERT definition into the __debug header to prevent this. 3. Remove external <__debug> include gaurds. <__debug> guards almost all of its contents internally. There is no reason to be doing it externally. This patch should not change any functionality. llvm-svn: 215332
* NFC. Remove trailing whitespace and tabs.Eric Fiselier2014-08-101-43/+43
| | | | llvm-svn: 215326
* [libcxx] expose experimental::erased_type for all standard versions.Eric Fiselier2014-07-241-4/+0
| | | | | | | | | | | | | | Summary: The polymorphic allocator implementation would greatly benefit by defining virtual functions in the dynlib instead of inline. In order to do that some types are going to have to be available outside of c++1y. This is the first step. Reviewers: mclow.lists, EricWF Reviewed By: EricWF Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D4554 llvm-svn: 213889
* Update the synopsis and comments with the results of LWG #2255. No code to ↵Marshall Clow2014-07-231-13/+13
| | | | | | back it up at the moment; just comments llvm-svn: 213768
* [libcxx] Add <experimental/utility> header for LFTS. Eric Fiselier2014-07-171-0/+48
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This patch adds the `<experimental/utility>` header as specified in the latest draft of the library fundamentals TS. `<experimental/utility>` only contains `class erased_type`. This patch also updates the documentation to list the `erased_type` class as "initial implementation complete". Test Plan: Three test cases where added: 1. Test that `_LIBCPP_VERSION` is defined. 2. Test that `<utility>` has been included. 3. Test that `erased_type` is in the correct namespace and is constexpr default constructible. Reviewers: mclow.lists Reviewed By: mclow.lists Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D4510 llvm-svn: 213226
* string_view enhancements. Move to the correct namespace. Better constexpr ↵Marshall Clow2014-07-082-11/+36
| | | | | | support (thanks to Richard for the suggestions). Update the tests to match this. Add <experimental/__config for experimental macros/etc to live. llvm-svn: 212569
* Minor cleanup for string_view; mostly from suggestions by Richard Smith. ↵Marshall Clow2014-07-021-18/+19
| | | | | | Also, make the tests pass under c++03 llvm-svn: 212185
* Formatting improvements in the <string_view> synopsis suggested by RSmith. ↵Marshall Clow2014-06-181-112/+111
| | | | | | No functionality change. llvm-svn: 211191
* Implement string_view from the library fundamentals TS (n4023). Also works ↵Marshall Clow2014-06-111-0/+813
| | | | | | in C++11 and 03, with reduced functionality (mostly in the area of constexpr) llvm-svn: 210659
* Use __builtin_operator_new/__builtin_operator_delete when available. ThisRichard Smith2014-06-041-2/+2
| | | | | | allows allocations and deallocations to be optimized out. llvm-svn: 210211
* Move <optional> into include/experimental, and into the std::experimental ↵Marshall Clow2013-11-151-0/+699
| | | | | | namespace, since it's not part of C++14, but of an upcoming TS llvm-svn: 194867
* Move <dynarray> into include/experimental, and into the std::experimental ↵Marshall Clow2013-11-131-0/+314
namespace, since it's not part of C++14, but of an upcoming TS llvm-svn: 194614
OpenPOWER on IntegriCloud