[PATCH] D56966: [clang-tidy] misc-non-private-member-variables-in-classes: ignore implicit methods

Roman Lebedev via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sun Jan 20 05:57:11 PST 2019


lebedev.ri added inline comments.


================
Comment at: docs/clang-tidy/checks/misc-non-private-member-variables-in-classes.rst:9
 
-Finds classes that contain non-static data members in addition to non-static
-member functions and diagnose all data members declared with a non-``public``
-access specifier. The data members should be declared as ``private`` and
-accessed through member functions instead of exposed to derived classes or
-class consumers.
+Finds classes that contain non-static data members in addition to user-provided
+non-static member functions and diagnose all data members declared with a
----------------
riccibruno wrote:
> Just a small remark: What do you mean exactly by "user-provided" ?
> 
> The term "user-provided" is defined in 11.4.2 [dcl.fct.def.default]/5 as
> 
> > A function is user-provided if it is user-declared and not explicitly
> > defaulted or deleted on its first declaration.
Yeah, i'm not sure what is the right word to use here,
suggestions welcomed.
The previous wording was confusing too, since non-implicit can be read as [[ https://en.cppreference.com/w/cpp/language/explicit | explicit specifier ]] which is not what is meant.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D56966/new/

https://reviews.llvm.org/D56966





More information about the cfe-commits mailing list