[PATCH] D143851: [clang-tidy] Tweak 'rule of 3/5' checks to allow defaulting a destructor outside the class.
Eugene Zelenko via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sun Feb 12 22:24:46 PST 2023
Eugene.Zelenko added inline comments.
================
Comment at: clang-tools-extra/docs/clang-tidy/checks/cppcoreguidelines/special-member-functions.rst:28
- When set to `true` (default is `false`), this check doesn't flag classes with a sole, explicitly
- defaulted destructor. An example for such a class is:
+ When set to `true` (default is `false`), this check will only trigger on destructors if they are defined and not defaulted.
----------------
Please follos 80 characters limit.
================
Comment at: clang-tools-extra/docs/clang-tidy/checks/cppcoreguidelines/special-member-functions.rst:40
+
+ struct C { // This is not checked, because the destuctor might be defaulted in another translation unit.
+ ~C();
----------------
ccotter wrote:
> typo: destuctor->destructor
Ditto.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D143851/new/
https://reviews.llvm.org/D143851
More information about the cfe-commits
mailing list