Balance the debug output of Lvalue Subslice

This commit is contained in:
Nicolas B. Pierron 2016-11-10 17:54:31 +00:00
parent 187d989602
commit 4ce4900218

View file

@ -923,7 +923,7 @@ impl<'tcx> Debug for Lvalue<'tcx> {
ProjectionElem::ConstantIndex { offset, min_length, from_end: true } =>
write!(fmt, "{:?}[-{:?} of {:?}]", data.base, offset, min_length),
ProjectionElem::Subslice { from, to } if to == 0 =>
write!(fmt, "{:?}[{:?}:", data.base, from),
write!(fmt, "{:?}[{:?}:]", data.base, from),
ProjectionElem::Subslice { from, to } if from == 0 =>
write!(fmt, "{:?}[:-{:?}]", data.base, to),
ProjectionElem::Subslice { from, to } =>