[libcxx-commits] [PATCH] D63574: Implement P0340R3: Make `underlying_type` SFINAE-friendly

Marshall Clow via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Wed Jun 19 16:47:47 PDT 2019


mclow.lists added a comment.

How many of these should fail?

  enum E1                   { E1Zero, E1One, E1Two = sizeof(std::underlying_type<E1>::type) };
  enum E2 : char            { E2Zero, E2One, E2Two = sizeof(std::underlying_type<E2>::type) };
  enum class E3             { E3Zero, E3One, E3Two = sizeof(std::underlying_type<E3>::type) };
  enum struct E4 : unsigned { E4Zero, E4One, E4Two = sizeof(std::underlying_type<E4>::type) };
  enum struct E5            { E5Zero, E5One, E5Two = sizeof(std::underlying_type<E5>::type) };
  enum class E6 : unsigned  { E6Zero, E6One, E6Two = sizeof(std::underlying_type<E6>::type) };

@rsmith ?


Repository:
  rCXX libc++

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

https://reviews.llvm.org/D63574





More information about the libcxx-commits mailing list