Address review comments

This commit is contained in:
Oliver Scherer 2020-03-11 09:39:58 +01:00
parent 2e91065a6f
commit db9ddf1cf1

View File

@ -1019,7 +1019,7 @@ pub trait PrettyPrinter<'tcx>:
)?;
}
// For function type zsts just printing the type is enough
(Scalar::Raw { size: 0, .. }, ty::FnDef(..)) => p!(print(ty)),
(Scalar::Raw { size: 0, .. }, ty::FnDef(d, s)) => p!(print_value_path(*d, s)),
// Empty tuples are frequently occurring, so don't print the fallback.
(Scalar::Raw { size: 0, .. }, ty::Tuple(ts)) if ts.is_empty() => p!(write("()")),
// Zero element arrays have a trivial representation.