@@ -492,7 +492,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
492492 Obligation {
493493 cause : cause. clone ( ) ,
494494 param_env : self . param_env ,
495- predicate : predicate. clone ( ) ,
495+ predicate : * predicate,
496496 recursion_depth : 0 ,
497497 } ,
498498 ) ) ;
@@ -676,7 +676,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
676676 let span = self_ty. span . ctxt ( ) . outer_expn_data ( ) . call_site ;
677677 let mut spans: MultiSpan = span. into ( ) ;
678678 spans. push_span_label ( span, derive_msg. to_string ( ) ) ;
679- let entry = spanned_predicates. entry ( spans. into ( ) ) ;
679+ let entry = spanned_predicates. entry ( spans) ;
680680 entry. or_insert_with ( || ( path, tr_self_ty, Vec :: new ( ) ) ) . 2 . push ( p) ;
681681 }
682682
@@ -704,7 +704,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
704704 ident. span . into ( )
705705 } ;
706706 spans. push_span_label ( ident. span , "in this trait" . to_string ( ) ) ;
707- let entry = spanned_predicates. entry ( spans. into ( ) ) ;
707+ let entry = spanned_predicates. entry ( spans) ;
708708 entry. or_insert_with ( || ( path, tr_self_ty, Vec :: new ( ) ) ) . 2 . push ( p) ;
709709 }
710710
@@ -748,7 +748,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
748748 }
749749 spans. push_span_label ( self_ty. span , String :: new ( ) ) ;
750750
751- let entry = spanned_predicates. entry ( spans. into ( ) ) ;
751+ let entry = spanned_predicates. entry ( spans) ;
752752 entry. or_insert_with ( || ( path, tr_self_ty, Vec :: new ( ) ) ) . 2 . push ( p) ;
753753 }
754754 _ => { }
@@ -1460,7 +1460,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
14601460 {
14611461 derives. push ( (
14621462 self_name. clone ( ) ,
1463- self_span. clone ( ) ,
1463+ self_span,
14641464 parent_diagnostic_name. to_string ( ) ,
14651465 ) ) ;
14661466 }
0 commit comments