File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed
compiler/rustc_infer/src/traits/error_reporting Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -101,11 +101,12 @@ pub fn report_object_safety_error<'tcx>(
101101 to be resolvable dynamically; for more information visit \
102102 <https://doc.rust-lang.org/reference/items/traits.html#object-safety>",
103103 ) ;
104+
105+ // Only provide the help if its a local trait, otherwise it's not actionable.
104106 if trait_span. is_some ( ) {
105107 let mut reported_violations: Vec < _ > = reported_violations. into_iter ( ) . collect ( ) ;
106108 reported_violations. sort ( ) ;
107109
108- // Only provide the help if its a local trait, otherwise it's not actionable.
109110 let mut potential_solutions: Vec < _ > =
110111 reported_violations. into_iter ( ) . map ( |violation| violation. solution ( ) ) . collect ( ) ;
111112 potential_solutions. sort ( ) ;
You can’t perform that action at this time.
0 commit comments