mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
`enum` is a signed integer type on some platforms. The return value of `std::numeric_limits<T>::max()` is a `size_t` which is unsigned. Further manipulation retains the unsigned-ness until the assignment which results in truncation. Change the type to a `constexpr` constant definition and remove the `enum` type along with a type conversion to an explicitly unsigned integral type.
22 KiB
22 KiB