Revert "sort suggestions for object diagnostic"
This reverts commit 540be28f6c
.
This commit is contained in:
parent
d325fb7c2e
commit
e0ba1931f4
4 changed files with 8 additions and 9 deletions
|
@ -177,13 +177,12 @@ pub fn report_object_safety_error<'tcx>(
|
|||
)));
|
||||
}
|
||||
impls => {
|
||||
let mut types = impls
|
||||
let types = impls
|
||||
.iter()
|
||||
.map(|t| {
|
||||
with_no_trimmed_paths!(format!(" {}", tcx.type_of(*t).instantiate_identity(),))
|
||||
})
|
||||
.collect::<Vec<_>>();
|
||||
types.sort();
|
||||
err.help(format!(
|
||||
"the following types implement the trait, consider defining an enum where each \
|
||||
variant holds one of these types, implementing `{}` for this new enum and using \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue