Skip to content

Commit c060b49

Browse files
committed
[Clang] Deprecate __is_referenceable
1 parent c25bd6e commit c060b49

File tree

2 files changed

+9
-4
lines changed

2 files changed

+9
-4
lines changed

clang/docs/LanguageExtensions.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1697,7 +1697,7 @@ The following type trait primitives are supported by Clang. Those traits marked
16971697
* ``__is_referenceable`` (C++, GNU, Microsoft, Embarcadero):
16981698
Returns true if a type is referenceable, and false otherwise. A referenceable
16991699
type is a type that's either an object type, a reference type, or an unqualified
1700-
function type.
1700+
function type. This trait is deprecated and will be removed in Clang 21.
17011701
* ``__is_rvalue_reference`` (C++, Embarcadero)
17021702
* ``__is_same`` (C++, Embarcadero)
17031703
* ``__is_same_as`` (GCC): Synonym for ``__is_same``.

clang/docs/ReleaseNotes.rst

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ C++ Specific Potentially Breaking Changes
9393
few users and can be written as ``__is_same(__remove_cv(T), decltype(nullptr))``,
9494
which GCC supports as well.
9595

96+
- The type trait builtin ``__is_referenceable`` has been deprecated, since it has
97+
very few users and all the type traits that could benefit from it in the
98+
standard library already have their own bespoke builtins. It will be removed in
99+
Clang 21.
100+
96101
- Clang will now correctly diagnose as ill-formed a constant expression where an
97102
enum without a fixed underlying type is set to a value outside the range of
98103
the enumeration's values.
@@ -310,7 +315,7 @@ C++23 Feature Support
310315

311316
- Extend lifetime of temporaries in mem-default-init for P2718R0. Clang now fully
312317
supports `P2718R0 Lifetime extension in range-based for loops <https://wg21.link/P2718R0>`_.
313-
318+
314319
- ``__cpp_explicit_this_parameter`` is now defined. (#GH82780)
315320

316321
C++20 Feature Support
@@ -715,7 +720,7 @@ Improvements to Clang's diagnostics
715720

716721
- Clang now diagnoses dangling references for C++20's parenthesized aggregate initialization (#101957).
717722

718-
- Fixed a bug where Clang would not emit ``-Wunused-private-field`` warnings when an unrelated class
723+
- Fixed a bug where Clang would not emit ``-Wunused-private-field`` warnings when an unrelated class
719724
defined a defaulted comparison operator (#GH116270).
720725

721726
.. code-block:: c++
@@ -934,7 +939,7 @@ Bug Fixes to C++ Support
934939
- Fixed an assertion failure caused by invalid default argument substitutions in non-defining
935940
friend declarations. (#GH113324)
936941
- Fix a crash caused by incorrect argument position in merging deduced template arguments. (#GH113659)
937-
- Fixed a parser crash when using pack indexing as a nested name specifier. (#GH119072)
942+
- Fixed a parser crash when using pack indexing as a nested name specifier. (#GH119072)
938943
- Fixed a null pointer dereference issue when heuristically computing ``sizeof...(pack)`` expressions. (#GH81436)
939944
- Fixed an assertion failure caused by mangled names with invalid identifiers. (#GH112205)
940945
- Fixed an incorrect lambda scope of generic lambdas that caused Clang to crash when computing potential lambda

0 commit comments

Comments
 (0)