[PATCH] D13313: [clang-tidy] new check misc-no-reinterpret-cast

Alexander Kornienko via cfe-commits cfe-commits at lists.llvm.org
Thu Oct 1 06:15:14 PDT 2015


alexfh added a comment.

A high-level comment: the "misc" module is the place for checks that we didn't find (or create) a better category for. Here it's clear that we need a separate category, so we need a `CppCoreGuidelinesModule` and the `cppcoreguidelines-` check prefix. I also suggest using anchor names (converted to lower case) in the document as check names, this one would be `cppcoreguidelines-pro-type-reinterpretcast`.


================
Comment at: test/clang-tidy/misc-no-reinterpret-cast.cpp:7
@@ +6,1 @@
+// CHECK-MESSAGES: :[[@LINE-1]]:16: warning: do not use reinterpret_cast (C++ Core Guidelines, rule Type.1) [misc-no-reinterpret-cast]
\ No newline at end of file

----------------
Please add a newline at the end of file to pacify various diff tools.


http://reviews.llvm.org/D13313





More information about the cfe-commits mailing list