[PATCH] D22507: Clang-tidy - Enum misuse check

Aaron Ballman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Dec 19 07:39:36 PST 2016


aaron.ballman added inline comments.


================
Comment at: clang-tidy/misc/SuspiciousEnumUsageCheck.cpp:31
+    "enum type seems like a bitmask (contains mostly "
+    "power-of-2 literals) but some literal(s) are not a power-of-2";
+
----------------
Please drop the `(s)` from the diagnostic. The phrase "but some literal are not" is incorrect. Alternatively, you could use the `%plural` diagnostic modifier (see `note_constexpr_baa_value_insufficient_alignment` in DiagnosticASTKinds.td for an example usage).


https://reviews.llvm.org/D22507





More information about the cfe-commits mailing list