mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-22 10:05:06 +03:00
Print constants in type_name for const generics
This commit is contained in:
@@ -237,7 +237,7 @@ fn print_const(mut self, ct: &'tcx ty::Const<'tcx>) -> Result<Self::Const, Self:
|
||||
// only print integers
|
||||
if let ty::ConstKind::Value(ConstValue::Scalar(Scalar::Raw { .. })) = ct.val {
|
||||
if ct.ty.is_integral() {
|
||||
return self.pretty_print_const(ct);
|
||||
return self.pretty_print_const(ct, true);
|
||||
}
|
||||
}
|
||||
self.write_str("_")?;
|
||||
|
||||
Reference in New Issue
Block a user