@@ -12,7 +12,7 @@ impl<'cx, 'tcx> crate::MirBorrowckCtxt<'cx, 'tcx> {
1212 place : & str ,
1313 borrow_place : & str ,
1414 value_place : & str ,
15- ) -> DiagnosticBuilder < ' cx , ErrorGuaranteed > {
15+ ) -> DiagnosticBuilder < ' tcx , ErrorGuaranteed > {
1616 self . infcx . tcx . sess . create_err ( crate :: session_diagnostics:: MoveBorrow {
1717 place,
1818 span,
@@ -28,7 +28,7 @@ impl<'cx, 'tcx> crate::MirBorrowckCtxt<'cx, 'tcx> {
2828 desc : & str ,
2929 borrow_span : Span ,
3030 borrow_desc : & str ,
31- ) -> DiagnosticBuilder < ' cx , ErrorGuaranteed > {
31+ ) -> DiagnosticBuilder < ' tcx , ErrorGuaranteed > {
3232 let mut err = struct_span_err ! (
3333 self ,
3434 span,
@@ -50,7 +50,7 @@ impl<'cx, 'tcx> crate::MirBorrowckCtxt<'cx, 'tcx> {
5050 old_loan_span : Span ,
5151 old_opt_via : & str ,
5252 old_load_end_span : Option < Span > ,
53- ) -> DiagnosticBuilder < ' cx , ErrorGuaranteed > {
53+ ) -> DiagnosticBuilder < ' tcx , ErrorGuaranteed > {
5454 let via =
5555 |msg : & str | if msg. is_empty ( ) { "" . to_string ( ) } else { format ! ( " (via {})" , msg) } ;
5656 let mut err = struct_span_err ! (
@@ -98,7 +98,7 @@ impl<'cx, 'tcx> crate::MirBorrowckCtxt<'cx, 'tcx> {
9898 desc : & str ,
9999 old_loan_span : Span ,
100100 old_load_end_span : Option < Span > ,
101- ) -> DiagnosticBuilder < ' cx , ErrorGuaranteed > {
101+ ) -> DiagnosticBuilder < ' tcx , ErrorGuaranteed > {
102102 let mut err = struct_span_err ! (
103103 self ,
104104 new_loan_span,
@@ -269,7 +269,7 @@ impl<'cx, 'tcx> crate::MirBorrowckCtxt<'cx, 'tcx> {
269269 & self ,
270270 span : Span ,
271271 desc : & str ,
272- ) -> DiagnosticBuilder < ' cx , ErrorGuaranteed > {
272+ ) -> DiagnosticBuilder < ' tcx , ErrorGuaranteed > {
273273 struct_span_err ! ( self , span, E0594 , "cannot assign to {}" , desc)
274274 }
275275
@@ -348,7 +348,7 @@ impl<'cx, 'tcx> crate::MirBorrowckCtxt<'cx, 'tcx> {
348348 span : Span ,
349349 path : & str ,
350350 reason : & str ,
351- ) -> DiagnosticBuilder < ' cx , ErrorGuaranteed > {
351+ ) -> DiagnosticBuilder < ' tcx , ErrorGuaranteed > {
352352 struct_span_err ! ( self , span, E0596 , "cannot borrow {} as mutable{}" , path, reason, )
353353 }
354354
@@ -359,7 +359,7 @@ impl<'cx, 'tcx> crate::MirBorrowckCtxt<'cx, 'tcx> {
359359 immutable_place : & str ,
360360 immutable_section : & str ,
361361 action : & str ,
362- ) -> DiagnosticBuilder < ' cx , ErrorGuaranteed > {
362+ ) -> DiagnosticBuilder < ' tcx , ErrorGuaranteed > {
363363 let mut err = struct_span_err ! (
364364 self ,
365365 mutate_span,
@@ -378,7 +378,7 @@ impl<'cx, 'tcx> crate::MirBorrowckCtxt<'cx, 'tcx> {
378378 & self ,
379379 span : Span ,
380380 yield_span : Span ,
381- ) -> DiagnosticBuilder < ' cx , ErrorGuaranteed > {
381+ ) -> DiagnosticBuilder < ' tcx , ErrorGuaranteed > {
382382 let mut err = struct_span_err ! (
383383 self ,
384384 span,
@@ -392,7 +392,7 @@ impl<'cx, 'tcx> crate::MirBorrowckCtxt<'cx, 'tcx> {
392392 pub ( crate ) fn cannot_borrow_across_destructor (
393393 & self ,
394394 borrow_span : Span ,
395- ) -> DiagnosticBuilder < ' cx , ErrorGuaranteed > {
395+ ) -> DiagnosticBuilder < ' tcx , ErrorGuaranteed > {
396396 struct_span_err ! (
397397 self ,
398398 borrow_span,
@@ -405,7 +405,7 @@ impl<'cx, 'tcx> crate::MirBorrowckCtxt<'cx, 'tcx> {
405405 & self ,
406406 span : Span ,
407407 path : & str ,
408- ) -> DiagnosticBuilder < ' cx , ErrorGuaranteed > {
408+ ) -> DiagnosticBuilder < ' tcx , ErrorGuaranteed > {
409409 struct_span_err ! ( self , span, E0597 , "{} does not live long enough" , path, )
410410 }
411411
@@ -415,7 +415,7 @@ impl<'cx, 'tcx> crate::MirBorrowckCtxt<'cx, 'tcx> {
415415 return_kind : & str ,
416416 reference_desc : & str ,
417417 path_desc : & str ,
418- ) -> DiagnosticBuilder < ' cx , ErrorGuaranteed > {
418+ ) -> DiagnosticBuilder < ' tcx , ErrorGuaranteed > {
419419 let mut err = struct_span_err ! (
420420 self ,
421421 span,
@@ -440,7 +440,7 @@ impl<'cx, 'tcx> crate::MirBorrowckCtxt<'cx, 'tcx> {
440440 closure_kind : & str ,
441441 borrowed_path : & str ,
442442 capture_span : Span ,
443- ) -> DiagnosticBuilder < ' cx , ErrorGuaranteed > {
443+ ) -> DiagnosticBuilder < ' tcx , ErrorGuaranteed > {
444444 let mut err = struct_span_err ! (
445445 self ,
446446 closure_span,
@@ -458,14 +458,14 @@ impl<'cx, 'tcx> crate::MirBorrowckCtxt<'cx, 'tcx> {
458458 pub ( crate ) fn thread_local_value_does_not_live_long_enough (
459459 & self ,
460460 span : Span ,
461- ) -> DiagnosticBuilder < ' cx , ErrorGuaranteed > {
461+ ) -> DiagnosticBuilder < ' tcx , ErrorGuaranteed > {
462462 struct_span_err ! ( self , span, E0712 , "thread-local variable borrowed past end of function" , )
463463 }
464464
465465 pub ( crate ) fn temporary_value_borrowed_for_too_long (
466466 & self ,
467467 span : Span ,
468- ) -> DiagnosticBuilder < ' cx , ErrorGuaranteed > {
468+ ) -> DiagnosticBuilder < ' tcx , ErrorGuaranteed > {
469469 struct_span_err ! ( self , span, E0716 , "temporary value dropped while borrowed" , )
470470 }
471471
0 commit comments