File tree Expand file tree Collapse file tree 1 file changed +3
-6
lines changed
compiler/rustc_parse/src/parser Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -246,9 +246,9 @@ impl MultiSugg {
246246#[ derive( SessionDiagnostic ) ]
247247#[ error( slug = "parser-maybe-report-ambiguous-plus" ) ]
248248struct AmbiguousPlus {
249- pub sum_with_parens : String ,
249+ pub sum_ty : String ,
250250 #[ primary_span]
251- #[ suggestion( code = "({sum_with_parens })" ) ]
251+ #[ suggestion( code = "({sum_ty })" ) ]
252252 pub span : Span ,
253253}
254254
@@ -1182,10 +1182,7 @@ impl<'a> Parser<'a> {
11821182 ty : & Ty ,
11831183 ) {
11841184 if matches ! ( allow_plus, AllowPlus :: No ) && impl_dyn_multi {
1185- self . sess . emit_err ( AmbiguousPlus {
1186- sum_with_parens : pprust:: ty_to_string ( & ty) ,
1187- span : ty. span ,
1188- } ) ;
1185+ self . sess . emit_err ( AmbiguousPlus { sum_ty : pprust:: ty_to_string ( & ty) , span : ty. span } ) ;
11891186 }
11901187 }
11911188
You can’t perform that action at this time.
0 commit comments