@@ -333,7 +333,7 @@ impl<'a: 'ast, 'ast> LateResolutionVisitor<'a, '_, 'ast> {
333333 let candidates = self
334334 . r
335335 . lookup_import_candidates ( ident, ns, & self . parent_scope , is_expected)
336- . drain ( .. )
336+ . into_iter ( )
337337 . filter ( |ImportSuggestion { did, .. } | {
338338 match ( did, res. and_then ( |res| res. opt_def_id ( ) ) ) {
339339 ( Some ( suggestion_did) , Some ( actual_did) ) => * suggestion_did != actual_did,
@@ -1554,7 +1554,7 @@ impl<'a: 'ast, 'ast> LateResolutionVisitor<'a, '_, 'ast> {
15541554 if suggest_only_tuple_variants {
15551555 // Suggest only tuple variants regardless of whether they have fields and do not
15561556 // suggest path with added parentheses.
1557- let mut suggestable_variants = variants
1557+ let suggestable_variants = variants
15581558 . iter ( )
15591559 . filter ( |( .., kind) | * kind == CtorKind :: Fn )
15601560 . map ( |( variant, ..) | path_names_to_string ( variant) )
@@ -1580,7 +1580,7 @@ impl<'a: 'ast, 'ast> LateResolutionVisitor<'a, '_, 'ast> {
15801580 err. span_suggestions (
15811581 span,
15821582 & msg,
1583- suggestable_variants. drain ( .. ) ,
1583+ suggestable_variants. into_iter ( ) ,
15841584 Applicability :: MaybeIncorrect ,
15851585 ) ;
15861586 }
@@ -1638,7 +1638,7 @@ impl<'a: 'ast, 'ast> LateResolutionVisitor<'a, '_, 'ast> {
16381638 ) ;
16391639 }
16401640
1641- let mut suggestable_variants_with_placeholders = variants
1641+ let suggestable_variants_with_placeholders = variants
16421642 . iter ( )
16431643 . filter ( |( _, def_id, kind) | needs_placeholder ( * def_id, * kind) )
16441644 . map ( |( variant, _, kind) | ( path_names_to_string ( variant) , kind) )
@@ -1663,7 +1663,7 @@ impl<'a: 'ast, 'ast> LateResolutionVisitor<'a, '_, 'ast> {
16631663 err. span_suggestions (
16641664 span,
16651665 msg,
1666- suggestable_variants_with_placeholders. drain ( .. ) ,
1666+ suggestable_variants_with_placeholders. into_iter ( ) ,
16671667 Applicability :: HasPlaceholders ,
16681668 ) ;
16691669 }
0 commit comments