]> git.lizzy.rs Git - rust.git/blobdiff - src/tools/clippy/clippy_lints/src/needless_pass_by_value.rs
Rollup merge of #87528 - :stack_overflow_obsd, r=joshtriplett
[rust.git] / src / tools / clippy / clippy_lints / src / needless_pass_by_value.rs
index 90b2aa16896267b3fd66d06d739a34a202d88db4..352dc6f8bec3dd7d07c621d211837dc870ae46d1 100644 (file)
@@ -206,7 +206,7 @@ fn check_fn(
 
                         let deref_span = spans_need_deref.get(&canonical_id);
                         if_chain! {
-                            if is_type_diagnostic_item(cx, ty, sym::vec_type);
+                            if is_type_diagnostic_item(cx, ty, sym::Vec);
                             if let Some(clone_spans) =
                                 get_spans(cx, Some(body.id()), idx, &[("clone", ".to_owned()")]);
                             if let TyKind::Path(QPath::Resolved(_, path)) = input.kind;
@@ -245,7 +245,7 @@ fn check_fn(
                             }
                         }
 
-                        if is_type_diagnostic_item(cx, ty, sym::string_type) {
+                        if is_type_diagnostic_item(cx, ty, sym::String) {
                             if let Some(clone_spans) =
                                 get_spans(cx, Some(body.id()), idx, &[("clone", ".to_string()"), ("as_str", "")]) {
                                 diag.span_suggestion(