1
Fork 0

only allow restricting scalar layouts

This commit is contained in:
Oliver Schneider 2018-09-10 14:39:22 +02:00
parent 833dc7e682
commit 88ebb95f46

View file

@ -779,7 +779,8 @@ impl<'a, 'tcx> LayoutCx<'tcx, TyCtxt<'a, 'tcx, 'tcx>> {
scalar.valid_range = *scalar.valid_range.start()..=end;
}
}
_ => bug!(
_ => assert!(
start == Bound::Unbounded && end == Bound::Unbounded,
"nonscalar layout for layout_scalar_valid_range type {:?}: {:#?}",
def,
st,