xref: /aosp_15_r20/external/cronet/third_party/libc++/src/docs/ReleaseNotes/19.rst (revision 6777b5387eb2ff775bb5750e3f5d96f37fb7352b)
1===========================================
2Libc++ 19.0.0 (In-Progress) Release Notes
3===========================================
4
5.. contents::
6   :local:
7   :depth: 2
8
9Written by the `Libc++ Team <https://libcxx.llvm.org>`_
10
11.. warning::
12
13   These are in-progress notes for the upcoming libc++ 19.0.0 release.
14   Release notes for previous releases can be found on
15   `the Download Page <https://releases.llvm.org/download.html>`_.
16
17Introduction
18============
19
20This document contains the release notes for the libc++ C++ Standard Library,
21part of the LLVM Compiler Infrastructure, release 19.0.0. Here we describe the
22status of libc++ in some detail, including major improvements from the previous
23release and new feature work. For the general LLVM release notes, see `the LLVM
24documentation <https://llvm.org/docs/ReleaseNotes.html>`_. All LLVM releases may
25be downloaded from the `LLVM releases web site <https://llvm.org/releases/>`_.
26
27For more information about libc++, please see the `Libc++ Web Site
28<https://libcxx.llvm.org>`_ or the `LLVM Web Site <https://llvm.org>`_.
29
30Note that if you are reading this file from a Git checkout or the
31main Libc++ web page, this document applies to the *next* release, not
32the current one. To see the release notes for a specific release, please
33see the `releases page <https://llvm.org/releases/>`_.
34
35What's New in Libc++ 19.0.0?
36==============================
37
38Implemented Papers
39------------------
40
41- P2637R3 - Member ``visit``
42- P2652R2 - Disallow User Specialization of ``allocator_traits``
43- P2819R2 - Add ``tuple`` protocol to ``complex``
44- P2495R3 - Interfacing ``stringstream``\s with ``string_view``
45- P2302R4 - ``std::ranges::contains``
46- P1659R3 - ``std::ranges::starts_with`` and ``std::ranges::ends_with``
47
48Improvements and New Features
49-----------------------------
50
51- The performance of growing ``std::vector`` has been improved for trivially relocatable types.
52- The performance of ``ranges::fill`` and ``ranges::fill_n`` has been improved for ``vector<bool>::iterator``\s,
53  resulting in a performance increase of up to 1400x.
54- The ``std::mismatch`` algorithm has been optimized for integral types, which can lead up to 40x performance
55  improvements.
56
57Deprecations and Removals
58-------------------------
59
60- TODO: The ``LIBCXX_ENABLE_ASSERTIONS`` CMake variable that was used to enable the safe mode has been deprecated and setting
61  it triggers an error; use the ``LIBCXX_HARDENING_MODE`` CMake variable with the value ``extensive`` instead. Similarly,
62  the ``_LIBCPP_ENABLE_ASSERTIONS`` macro has been deprecated (setting it to ``1`` still enables the extensive mode in
63  the LLVM 19 release while also issuing a deprecation warning). See :ref:`the hardening documentation
64  <using-hardening-modes>` for more details.
65
66- The base template for ``std::char_traits`` has been removed in LLVM 19. If you are using ``std::char_traits`` with
67  types other than ``char``, ``wchar_t``, ``char8_t``, ``char16_t``, ``char32_t`` or a custom character type for which you
68  specialized ``std::char_traits``, your code will stop working. The Standard does not mandate that a base template is
69  provided, and such a base template is bound to be incorrect for some types, which could currently cause unexpected behavior
70  while going undetected.
71
72- The ``_LIBCPP_ENABLE_NARROWING_CONVERSIONS_IN_VARIANT`` macro that changed the behavior for narrowing conversions
73  in ``std::variant`` has been removed in LLVM 19.
74
75- The ``_LIBCPP_ENABLE_CXX20_REMOVED_ALLOCATOR_MEMBERS`` and ``_LIBCPP_ENABLE_CXX20_REMOVED_ALLOCATOR_VOID_SPECIALIZATION``
76  macros have been removed in LLVM 19.
77
78- TODO: The ``_LIBCPP_ENABLE_CXX17_REMOVED_FEATURES`` and ``_LIBCPP_ENABLE_CXX20_REMOVED_FEATURES`` macros have
79  been removed in LLVM 19. C++17 and C++20 removed features can still be re-enabled individually.
80
81- The ``_LIBCPP_INLINE_VISIBILITY`` and ``_VSTD`` macros have been removed in LLVM 19.
82
83- The ``_LIBCPP_ATOMIC_ONLY_USE_BUILTINS`` configuration option has been removed in LLVM 19. This should not affect
84  many users, except perhaps users using the library with ``-ffreestanding`` with a toolchain where compiler-rt or
85  libatomic is not available. If you are one such user, please reach out to the libc++ developers so we can collaborate
86  on a path for supporting atomics properly on freestanding platforms.
87
88
89Upcoming Deprecations and Removals
90----------------------------------
91
92LLVM 20
93~~~~~~~
94
95- The ``LIBCXX_ENABLE_ASSERTIONS`` CMake variable and the ``_LIBCPP_ENABLE_ASSERTIONS`` macro that were used to enable
96  the safe mode will be removed in LLVM 20.
97
98LLVM 21
99~~~~~~~
100TODO
101
102
103ABI Affecting Changes
104---------------------
105TODO
106
107
108Build System Changes
109--------------------
110
111- The ``LIBCXX_EXECUTOR`` and ``LIBCXXABI_EXECUTOR`` CMake variables have been removed. Please
112  set ``LIBCXX_TEST_PARAMS`` to ``executor=<...>`` instead.
113