[PATCH] D32700: [clang-tidy] Add bugprone-suspicious-memset-usage check.

Alexander Kornienko via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Jul 14 03:47:55 PDT 2017


alexfh accepted this revision.
alexfh added a comment.
This revision is now accepted and ready to land.

Looks good with a single comment.

Thank you for working on this!



================
Comment at: clang-tidy/bugprone/SuspiciousMemsetUsageCheck.cpp:74-75
+
+  // Case 2: fill_char of memset() is larger in size than an unsigned char so
+  // it gets truncated during conversion.
+  else if (const auto *NumFill =
----------------
The formatting is rather misleading here. Let's put the comment inside the `if`. Same below.


https://reviews.llvm.org/D32700





More information about the cfe-commits mailing list