[PATCH] D15685: [clang-tidy] introducing cppcoreguidelines-enum-all-caps check
Kirill Bobyrev via cfe-commits
cfe-commits at lists.llvm.org
Mon Dec 21 00:55:15 PST 2015
omtcyf0 created this revision.
omtcyf0 added reviewers: alexfh, chapuni, klimek.
omtcyf0 added a subscriber: cfe-commits.
This patch introduces cppcoreguidelines-enum-all-caps, which flags all ALL_CAPS enumerations.
As written in C++ Core Guidelines: enumerations should not be named using ALL_CAPS to avoid clashes with macros.
This rule is part of the "Enumerations" profile of the C++ Core Guidelines, see
https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md#-enum5-dont-use-all_caps-for-enumerators
http://reviews.llvm.org/D15685
Files:
clang-tidy/cppcoreguidelines/CMakeLists.txt
clang-tidy/cppcoreguidelines/CppCoreGuidelinesTidyModule.cpp
clang-tidy/cppcoreguidelines/EnumAllCapsCheck.cpp
clang-tidy/cppcoreguidelines/EnumAllCapsCheck.h
docs/clang-tidy/checks/cppcoreguidelines-enum-all-caps.rst
docs/clang-tidy/checks/list.rst
test/clang-tidy/cppcoreguidelines-enum-all-caps.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D15685.43347.patch
Type: text/x-patch
Size: 6890 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20151221/2d14d0f1/attachment-0001.bin>
More information about the cfe-commits
mailing list