[PATCH] D150226: [Clang] Remove ability to downgrade warning on the diagnostic for setting a non fixed enum to a value outside the range of the enumeration values

Manoj Gupta via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu May 11 19:42:51 PDT 2023


manojgupta added a comment.

We also use Wno-enum-constexpr-conversion in ChromeOS. There are many packages that break with this warning. One of them is boost which is used in many other packages.

The errors in boost were:

  ./boost/mpl/aux_/integral_wrapper.hpp:73:31: error: integer value -1 is outside the valid range of values [0, 3] for this enumeration type [-Wenum-constexpr-conversion]
  ./boost/mpl/aux_/static_cast.hpp:24:47: note: expanded from macro 'BOOST_MPL_AUX_STATIC_CAST'
  #   define BOOST_MPL_AUX_STATIC_CAST(T, expr) static_cast<T>(expr)
                                                ^

I do not think boost upstream has updated these files, I see they were last updated 3 years back.
https://github.com/boostorg/mpl/blob/master/include/boost/mpl/aux_/static_cast.hpp
and https://github.com/boostorg/mpl/blob/master/include/boost/mpl/aux_/integral_wrapper.hpp


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D150226/new/

https://reviews.llvm.org/D150226



More information about the cfe-commits mailing list