[PATCH] D97491: [clang-tidy] Deprecate readability-deleted-default check
Nathan James via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Mar 3 08:01:26 PST 2021
This revision was automatically updated to reflect the committed changes.
Closed by commit rG19aefd2d5dc3: [clang-tidy] Deprecate readability-deleted-default check (authored by njames93).
Changed prior to commit:
https://reviews.llvm.org/D97491?vs=326449&id=327802#toc
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D97491/new/
https://reviews.llvm.org/D97491
Files:
clang-tools-extra/docs/ReleaseNotes.rst
clang-tools-extra/docs/clang-tidy/checks/readability-deleted-default.rst
Index: clang-tools-extra/docs/clang-tidy/checks/readability-deleted-default.rst
===================================================================
--- clang-tools-extra/docs/clang-tidy/checks/readability-deleted-default.rst
+++ clang-tools-extra/docs/clang-tidy/checks/readability-deleted-default.rst
@@ -3,20 +3,6 @@
readability-deleted-default
===========================
-Checks that constructors and assignment operators marked as ``= default`` are
-not actually deleted by the compiler.
-
-.. code-block:: c++
-
- class Example {
- public:
- // This constructor is deleted because I is missing a default value.
- Example() = default;
- // This is fine.
- Example(const Example& Other) = default;
- // This operator is deleted because I cannot be assigned (it is const).
- Example& operator=(const Example& Other) = default;
-
- private:
- const int I;
- };
+This check has been deprecated prefer to make use of the `Wdefaulted-function-deleted
+<https://clang.llvm.org/docs/DiagnosticsReference.html#wdefaulted-function-deleted>`_
+flag.
Index: clang-tools-extra/docs/ReleaseNotes.rst
===================================================================
--- clang-tools-extra/docs/ReleaseNotes.rst
+++ clang-tools-extra/docs/ReleaseNotes.rst
@@ -112,6 +112,16 @@
function or assignment to ``nullptr``.
Added support for pointers to ``std::unique_ptr``.
+Deprecated checks
+^^^^^^^^^^^^^^^^^
+
+- The :doc:`readability-deleted-default
+ <clang-tidy/checks/readability-deleted-default>` check has been deprecated.
+
+ The clang warning `Wdefaulted-function-deleted
+ <https://clang.llvm.org/docs/DiagnosticsReference.html#wdefaulted-function-deleted>`_
+ will diagnose the same issues and is enabled by default.
+
Improvements to include-fixer
-----------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D97491.327802.patch
Type: text/x-patch
Size: 1824 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20210303/40b4f124/attachment.bin>
More information about the cfe-commits
mailing list