[PATCH] D18265: [clang-tidy] New: checker misc-assign-operator-return

Alexander Kornienko via cfe-commits cfe-commits at lists.llvm.org
Wed Mar 30 06:23:53 PDT 2016


alexfh added a comment.

In http://reviews.llvm.org/D18265#386720, @baloghadamsoftware wrote:

> Actually, there was nothing wrong with assign operator signatures per se either although the original name of the checker was AssignOperatorSignature. The only change here is that it does not check the signature only anymore, but also the body (if present).


Maybe the old check name should have been `misc-unconventional-assign-operator-signature` or something like that, but even the old name limited the scope enough to make it easy to guess about the possible issues it flags. However, further expanding the scope makes the name even less informative. There are just too many things that could be wrong with assignment operators. If/when we add a check for another bug-prone pattern related to assignment operators, the name `misc-assign-operator` could be broad enough to cover this hypothetical new check as well. This will inevitably lead to confusion.


http://reviews.llvm.org/D18265





More information about the cfe-commits mailing list