Test validity of pattern types by oli-obk · Pull Request #136145 · rust-lang/rust (original) (raw)
Surely patterns can express more than what fits into rustc_layout_scalar_valid_range? We should check the actual pattern, if it is relevant for validity. I assume even non-scalar types can have a pattern?
So some tests that probably still fail are:
- transmute
10topattern_type!(u32 is 1..10 | 11..) - transmute
(0, 0, 0)topattern_type!((u32, u32, u32) is (1.., 1.., 1..))