We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
is_scoped_enum_v
1 parent 001cc34 commit 31a9c44Copy full SHA for 31a9c44
llvm/include/llvm/ADT/STLForwardCompat.h
@@ -73,7 +73,8 @@ struct from_range_t {
73
};
74
inline constexpr from_range_t from_range{};
75
76
-template <typename T, typename UnderlyingT = std::underlying_type_t<T>>
+template <typename T, typename UnderlyingT = typename std::enable_if_t<
77
+ std::is_enum_v<T>, std::underlying_type<T>>::type>
78
constexpr bool is_scoped_enum_v =
79
std::is_enum_v<T> && !std::is_convertible_v<T, UnderlyingT>;
80
0 commit comments