Skip to content

Commit b2d66ec

Browse files
committed
Use static_assert(false)
1 parent 2a4e05f commit b2d66ec

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

source/bounded/underlying_type_t.cpp

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,6 @@ constexpr auto range_fits_in_type(auto const minimum, auto const maximum) {
2424
value_fits_in_type<T>(maximum);
2525
}
2626

27-
template<auto...>
28-
constexpr auto false_ = false;
29-
3027
template<auto minimum, auto maximum>
3128
constexpr auto determine_type() {
3229
if constexpr (range_fits_in_type<unsigned char>(minimum, maximum)) {
@@ -56,7 +53,7 @@ constexpr auto determine_type() {
5653
return type<numeric_traits::int128_t>;
5754
#endif
5855
} else {
59-
static_assert(false_<minimum, maximum>, "Bounds cannot fit in any type.");
56+
static_assert(false, "Bounds cannot fit in any type.");
6057
}
6158
}
6259

0 commit comments

Comments
 (0)