Commit Graph

658 Commits

Author SHA1 Message Date
Marshall Clow
3826bf7c10 Update c++2a status page with post-Cologne information
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@366696 91177308-0d34-0410-b5e6-96231b3b80d8
2019-07-22 15:13:14 +00:00
Zoe Carver
3f39fe31c4 Add contains method to associative containers. This patch implements P0458R2, adding contains to map, multimap, unordered_map, unordered_multimap, set, multiset, unordered_set, and unordered_multiset.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@366170 91177308-0d34-0410-b5e6-96231b3b80d8
2019-07-16 03:21:01 +00:00
Louis Dionne
c59091fb03 [libc++] Implement P0433: deduction guides for <unordered_map>
Thanks to Arthur O'Dwyer for the patch.

Differential Revision: https://reviews.llvm.org/D58590

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@366124 91177308-0d34-0410-b5e6-96231b3b80d8
2019-07-15 20:06:01 +00:00
Marshall Clow
7d00fc23cd Add tests for regex_match ambiguity (aka LWG2273). NFC. Reviewed as https://reviews.llvm.org/D63051
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@365080 91177308-0d34-0410-b5e6-96231b3b80d8
2019-07-03 20:32:35 +00:00
Marshall Clow
cdd813e070 Update status of papers for upcoming WG21 meeting. NFC
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@364885 91177308-0d34-0410-b5e6-96231b3b80d8
2019-07-02 03:23:06 +00:00
Marshall Clow
268aced50d Update status for bit operations
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@364863 91177308-0d34-0410-b5e6-96231b3b80d8
2019-07-01 23:00:34 +00:00
Marshall Clow
b10aebc767 Implement LWG2221: 'Formatted output for nullptr_t' Reviewed as: https://reviews.llvm.org/D63053
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@364802 91177308-0d34-0410-b5e6-96231b3b80d8
2019-07-01 16:20:25 +00:00
Zhihao Yuan
b0473a5282 [libc++] Recommit r363692 to implement P0608R3
Re-apply the change which was reverted in r363764 as-is after
breakages being resolved.  Thanks Eric Fiselier for working
hard on this.

See also: https://bugs.llvm.org/show_bug.cgi?id=42330

Differential Revision: https://reviews.llvm.org/D44865


git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@363993 91177308-0d34-0410-b5e6-96231b3b80d8
2019-06-20 22:09:40 +00:00
Marshall Clow
8dda700081 Mark papers P1458, P1459, P1462 and P1464 as complete. No changed needed to either the library or the tests.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@363834 91177308-0d34-0410-b5e6-96231b3b80d8
2019-06-19 16:32:07 +00:00
Zhihao Yuan
1d7f21ea6f [libc++] Revert r363692 which implements P0608R3
The change caused a large number of compiler failures in
Google's codebase.  People need time to evaluate the impact.



git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@363764 91177308-0d34-0410-b5e6-96231b3b80d8
2019-06-19 07:11:08 +00:00
Zhihao Yuan
f8f62ac93c [libc++] Implement P0608R3 - A sane variant converting constructor
Summary:
Prefer user-defined conversions over narrowing conversions and conversions to bool.

References:
 http://wg21.link/p0608

Reviewers: EricWF, mpark, mclow.lists

Reviewed By: mclow.lists

Subscribers: zoecarver, ldionne, libcxx-commits, cfe-commits, christof

Differential Revision: https://reviews.llvm.org/D44865

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@363692 91177308-0d34-0410-b5e6-96231b3b80d8
2019-06-18 15:26:50 +00:00
Louis Dionne
5f9e5208e6 [NFC] Assign a couple of LWG issues to myself
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@363605 91177308-0d34-0410-b5e6-96231b3b80d8
2019-06-17 19:40:09 +00:00
Marshall Clow
166dca8cc8 Update status of issue 3209
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@363594 91177308-0d34-0410-b5e6-96231b3b80d8
2019-06-17 18:25:52 +00:00
Marshall Clow
a5a011702c Add tests for LWG 3206. NFC
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@363589 91177308-0d34-0410-b5e6-96231b3b80d8
2019-06-17 18:06:30 +00:00
Marshall Clow
9cbdf27f7c Update the meeting page with papers/issues that are ready for Cologne
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@363575 91177308-0d34-0410-b5e6-96231b3b80d8
2019-06-17 16:17:56 +00:00
Louis Dionne
4211451486 [libcxx] Slightly improved policy for handling experimental features
Summary:
Following the discussion on the libcxx-dev mailing list
(http://lists.llvm.org/pipermail/libcxx-dev/2019-May/000358.html),
this implements the new policy for handling experimental features and
their deprecation. We basically add a deprecation warning for
std::experimental::filesystem, and we remove a bunch of <experimental/*>
headers that were now empty.

Reviewers: mclow.lists, EricWF

Subscribers: mgorny, christof, jkorous, dexonsmith, arphaman, libcxx-commits, jfb

Tags: #libc

Differential Revision: https://reviews.llvm.org/D62428

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@363072 91177308-0d34-0410-b5e6-96231b3b80d8
2019-06-11 14:48:40 +00:00
Marshall Clow
0174d760ef Update issue statuses. Reviewed as https://reviews.llvm.org/D62932
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@362659 91177308-0d34-0410-b5e6-96231b3b80d8
2019-06-05 21:52:19 +00:00
Eric Fiselier
2444283c62 Update C++2a status for destroying delete
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@361574 91177308-0d34-0410-b5e6-96231b3b80d8
2019-05-24 00:10:33 +00:00
Marshall Clow
61ca0bbf14 Add a test for LWG#3204 and mark it as complete. Reviewed as https://reviews.llvm.org/D61829 Thanks to Zoe for the patch.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@360586 91177308-0d34-0410-b5e6-96231b3b80d8
2019-05-13 14:56:02 +00:00
Marshall Clow
cac04cde5e Implement LWG 2960: nonesuch is insufficiently useless
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@359526 91177308-0d34-0410-b5e6-96231b3b80d8
2019-04-30 00:54:38 +00:00
Marshall Clow
c5b17c65dc Mark LWG#2977 as 'Nothing to do'. NFC
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@359525 91177308-0d34-0410-b5e6-96231b3b80d8
2019-04-30 00:54:26 +00:00
Marshall Clow
732332686b Add tests specifically for LWG2164. We already did this; but now we have tests. NFC
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@359458 91177308-0d34-0410-b5e6-96231b3b80d8
2019-04-29 15:38:07 +00:00
Marshall Clow
e84fd85b88 Implement 'lerp'; which is the last bit of P0811. Mark that paper as complete.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@359211 91177308-0d34-0410-b5e6-96231b3b80d8
2019-04-25 17:44:18 +00:00
Eric Fiselier
250205c9d2 Add std::is_constant_evaluated.
Clang recently added __builtin_is_constant_evaluated() and GCC 9.0
has it as well.

This patch adds support for it in libc++.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@359119 91177308-0d34-0410-b5e6-96231b3b80d8
2019-04-24 17:54:25 +00:00
Eric Fiselier
dbd4f51025 Fix implementation of ::abs and std::abs LWG 2192.
Summary:
All overloads of `::abs` and `std::abs` must be present in both `<cmath>` and `<cstdlib>`. This is problematic to implement because C defines `fabs` in `math.h` and `labs` in `stdlib.h`. This introduces a circular dependency between the two headers. 

This patch implements that requirement by moving `abs` into `math.h` and making `stdlib.h` include `math.h`. In order to get the underlying C declarations from the "real" `stdlib.h` inside our `math.h` we need some trickery. Specifically we need to make `stdlib.h` include next itself.

Suggestions for a cleaner implementation are welcome.

Reviewers: mclow.lists, ldionne

Reviewed By: ldionne

Subscribers: krytarowski, fedor.sergeev, dexonsmith, jdoerfert, jsji, libcxx-commits

Differential Revision: https://reviews.llvm.org/D60097

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@359020 91177308-0d34-0410-b5e6-96231b3b80d8
2019-04-23 18:01:58 +00:00
Louis Dionne
d8ae8539a7 [libc++] Use std::is_nothrow_callable for std::invoke according to LWG 2807
Thanks to Zoe Carver for the patch.
Differential Revision: https://reviews.llvm.org/D58097

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@357616 91177308-0d34-0410-b5e6-96231b3b80d8
2019-04-03 17:54:37 +00:00
Louis Dionne
7b9927381c [libcxx] Make sure reference_wrapper works with incomplete types
Summary: Completes P0357R3, which was merged into the C++20 Working Draft in San Diego.

Reviewers: EricWF, mclow.lists

Subscribers: christof, jkorous, dexonsmith, libcxx-commits

Differential Revision: https://reviews.llvm.org/D54722

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@357423 91177308-0d34-0410-b5e6-96231b3b80d8
2019-04-01 19:53:44 +00:00
Louis Dionne
3af5f5e110 [libc++][CMake] Clean up some of the libc++ re-exporting logic
Summary:
This change allows specifying the version of libc++abi's ABI to re-export
when configuring CMake. It also clearly identifies which ABI version of
libc++abi each export file contains.

Finally, it removes hardcoded knowledge about the 10.9 SDK for MacOS,
since that knowledge is not relevant anymore. Indeed, libc++ can't be
built with the toolchain that came with the 10.9 SDK anyway because
the version of Clang it includes is too old (for example if you want
to build a working libc++.dylib, you need bugfixes to visibility
attributes that are only in recent Clangs).

Reviewers: dexonsmith, EricWF

Subscribers: mgorny, christof, jkorous, arphaman, libcxx-commits

Differential Revision: https://reviews.llvm.org/D59489

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@356587 91177308-0d34-0410-b5e6-96231b3b80d8
2019-03-20 18:16:24 +00:00
Eric Fiselier
158cd4dca0 LWG 2843 "Unclear behavior of std::pmr::memory_resource::do_allocate()"
Patch by Arthur O'Dwyer.
Reviewed as https://reviews.llvm.org/D47344

new_delete_resource().allocate(n, a) has basically two permissible results:

* Return an appropriately sized and aligned block.
* Throw bad_alloc.

Before this patch, libc++'s new_delete_resource would do a third and impermissible thing, which was
to return an appropriately sized but inappropriately under-aligned block. This is now fixed.

(This came up while I was stress-testing unsynchronized_pool_resource on my MacBook. If we can't
trust the default resource to return appropriately aligned blocks, pretty much everything breaks.
For similar reasons, I would strongly support just patching __libcpp_allocate directly, but I don't
care to die on that hill, so I made this patch as a <memory_resource>-specific workaround.)

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@355763 91177308-0d34-0410-b5e6-96231b3b80d8
2019-03-09 00:38:19 +00:00
Davide Italiano
a011222d74 Reinstate libc++ patches now that the lldb formatter has been updated.
"[libc++] Fix <atomic> failures on GCC"
"[libc++] Change memory_order to an enum class"
"[libc++] decoupling Freestanding atomic<T> from libatomic.a"

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@355427 91177308-0d34-0410-b5e6-96231b3b80d8
2019-03-05 18:40:49 +00:00
Davide Italiano
3438c15d15 [libcxx] Revert set of atomic patches that broke lldb.
Revert "[libc++] Fix <atomic> failures on GCC"
Revert "[libc++] Change memory_order to an enum class"
Revert "[libc++] decoupling Freestanding atomic<T> from libatomic.a"

The lldb formatter nededs to be updated. Shafik and Louis will
coordinate to do so.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@355417 91177308-0d34-0410-b5e6-96231b3b80d8
2019-03-05 17:38:33 +00:00
Louis Dionne
1bf0d1eb64 [libc++] Change memory_order to an enum class
This implements P0439R0.

Thanks to Zoe Carver for the patch.
Differential Revision: https://reviews.llvm.org/D58201

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@355403 91177308-0d34-0410-b5e6-96231b3b80d8
2019-03-05 14:50:25 +00:00
Louis Dionne
aeeba70ab1 [libc++] Add is_nothrow_convertible from P0758R1
Reviewed as https://reviews.llvm.org/D58019.
Thanks to Zoe Carver for the patch.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@355010 91177308-0d34-0410-b5e6-96231b3b80d8
2019-02-27 17:57:38 +00:00
Marshall Clow
ae4afd034b Implment the last part of P1024: tuple-like interface to span. Reviewed as https://reviews.llvm.org/D58706.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@354988 91177308-0d34-0410-b5e6-96231b3b80d8
2019-02-27 15:41:37 +00:00
Marshall Clow
f7374c69a9 Remove P1272R1, it was not moved in Kona
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@354904 91177308-0d34-0410-b5e6-96231b3b80d8
2019-02-26 18:17:30 +00:00
Marshall Clow
b0560e2ae9 Put a 'first implemented' version into the entry for P1357
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@354901 91177308-0d34-0410-b5e6-96231b3b80d8
2019-02-26 17:22:47 +00:00
Marshall Clow
02ee9a6e9a Mark several issues (and one paper) as complete. Reviewed as D58099; but I added LWG3101 and LWG3144 and P1357R1 as well.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@354898 91177308-0d34-0410-b5e6-96231b3b80d8
2019-02-26 17:01:00 +00:00
Marshall Clow
1c2f15d4c4 Update status page with papers/issues adopted in Kona
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@354796 91177308-0d34-0410-b5e6-96231b3b80d8
2019-02-25 16:12:00 +00:00
James Y Knight
e0324cb307 Adjust documentation for git migration.
This fixes most references to the paths:
 llvm.org/svn/
 llvm.org/git/
 llvm.org/viewvc/
 github.com/llvm-mirror/
 github.com/llvm-project/
 reviews.llvm.org/diffusion/

to instead point to https://github.com/llvm/llvm-project.

This is *not* a trivial substitution, because additionally, all the
checkout instructions had to be migrated to instruct users on how to
use the monorepo layout, setting LLVM_ENABLE_PROJECTS instead of
checking out various projects into various subdirectories.

I've attempted to not change any scripts here, only documentation. The
scripts will have to be addressed separately.

Additionally, I've deleted one document which appeared to be outdated
and unneeded:
  lldb/docs/building-with-debug-llvm.txt

Differential Revision: https://reviews.llvm.org/D57330

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@352514 91177308-0d34-0410-b5e6-96231b3b80d8
2019-01-29 16:37:27 +00:00
Eric Fiselier
427fc9484c update upcoming meeting issue status
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@352339 91177308-0d34-0410-b5e6-96231b3b80d8
2019-01-28 02:59:01 +00:00
Marshall Clow
56e3b48754 Note that we have a patch for LWG3101
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@351832 91177308-0d34-0410-b5e6-96231b3b80d8
2019-01-22 16:22:53 +00:00
Marshall Clow
844067dc76 Updated issue 3144
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@351773 91177308-0d34-0410-b5e6-96231b3b80d8
2019-01-22 01:05:58 +00:00
Marshall Clow
cb6b6cda0f Update with issues to be moved in San Diego
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@351770 91177308-0d34-0410-b5e6-96231b3b80d8
2019-01-22 00:31:09 +00:00
Louis Dionne
134a848236 [libcxx] Reorganize tests since the application of P0602R4
Summary:
P0602R4 makes the special member functions of optional and variant
conditionally trivial based on the types in the optional/variant.
We already implemented that, but the tests were organized as if this
were a non-standard extension. This patch reorganizes the tests in a
way that makes more sense since this is not an extension anymore.

Reviewers: EricWF, mpark, mclow.lists

Subscribers: christof, jkorous, dexonsmith, libcxx-commits

Differential Revision: https://reviews.llvm.org/D54772

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@350884 91177308-0d34-0410-b5e6-96231b3b80d8
2019-01-10 20:06:11 +00:00
Eric Fiselier
da05bdc85c Implement LWG 3096: path::lexically_relative is confused by trailing slashes
path("/dir/").lexically_relative("/dir"); now returns "." instead of ""

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@349885 91177308-0d34-0410-b5e6-96231b3b80d8
2018-12-21 04:25:40 +00:00
Eric Fiselier
3cf34d1caf Implement LWG 3065: Make path operators friends.
This prevents things like:

using namespace std::filesystem;
auto x = L"a/b" == std::string("a/b");

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@349884 91177308-0d34-0410-b5e6-96231b3b80d8
2018-12-21 04:09:01 +00:00
Eric Fiselier
874280d14d Implement LWG 3145: file_clock breaks ABI for C++17 implementations.
This patch adds std::chrono::file_clock, but without breaking the
existing ABI for std::filesystem.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@349883 91177308-0d34-0410-b5e6-96231b3b80d8
2018-12-21 03:54:57 +00:00
Eric Fiselier
a2037284d4 Implement LWG 2936: Path comparison is defined in terms of the generic format
This patch implements path::compare according to the current spec. The
only observable change is the ordering of "/foo" and "foo", which orders
the two paths based on having or not having a root directory (instead
of lexically comparing "/" to "foo").

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@349881 91177308-0d34-0410-b5e6-96231b3b80d8
2018-12-21 03:16:30 +00:00
Eric Fiselier
545d0b950d Mark two filesystem LWG issues as complete - nothing to do
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@349877 91177308-0d34-0410-b5e6-96231b3b80d8
2018-12-21 02:17:00 +00:00
Marshall Clow
f927635d87 Implement P1209 - Adopt Consistent Container Erasure from Library Fundamentals 2 for C++20. Reviewed as https://reviews.llvm.org/D55532
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@349178 91177308-0d34-0410-b5e6-96231b3b80d8
2018-12-14 18:49:35 +00:00