[PATCH] D131307: [Clang] Allow downgrading to a warning the diagnostic for setting a non fixed enum to a value outside the range of the enumeration values
Shafik Yaghmour via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Aug 5 18:02:45 PDT 2022
shafik created this revision.
shafik added reviewers: aaron.ballman, erichkeane, thakis, smeenai, tahonermann.
Herald added a project: All.
shafik requested review of this revision.
In D130058 <https://reviews.llvm.org/D130058> we diagnose the undefined behavior of setting the value outside the range of the enumerations values for an enum without a fixed underlying type.
Based on feedback we will provide users to the ability to downgrade this this diagnostic to a waring to allow for a transition period. We expect to turn this diagnostic to an error in the next release.
https://reviews.llvm.org/D131307
Files:
clang/docs/ReleaseNotes.rst
clang/include/clang/Basic/DiagnosticASTKinds.td
clang/lib/AST/ExprConstant.cpp
clang/test/SemaCXX/MicrosoftCompatibility.cpp
clang/test/SemaCXX/compare.cpp
clang/test/SemaCXX/constant-expression-cxx11.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D131307.450455.patch
Type: text/x-patch
Size: 9198 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20220806/aebe78f8/attachment-0001.bin>
More information about the cfe-commits
mailing list