[PATCH] D32346: [clang-tidy] New readability check for strlen argument
Eugene Zelenko via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Apr 21 07:39:49 PDT 2017
Eugene.Zelenko added a comment.
Please mention this check in docs/ReleaseNotes.rst (in alphabetical order).
================
Comment at: docs/clang-tidy/checks/readability-strlen-argument.rst:6
+
+This checker will detect addition in strlen() argument. Example code:
+
----------------
JonasToth wrote:
> Could you please add a little more motivational text to it?
> As I understand it, the wanted goal is to get the length of a substring, denoted as `char*`. Am I right?
> You could give a more fully code example showing the equivalence.
>
> `const char* = "Some super nice string"; ....`
Please use check, not checker. Please enclose strlen() into ``.
Repository:
rL LLVM
https://reviews.llvm.org/D32346
More information about the cfe-commits
mailing list