Make discriminant default type validation edition-proof
Changed
- Use safe casting in
PartialOrd
andOrd
implementations in more cases when
possible. - Avoid unnecessarily validating the default discriminant type in some cases.
- Apply default enum discriminant type validation to all representations and
make it cross-edition safe.