mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-10 23:24:24 +00:00
remove unused imports
This commit is contained in:
parent
c711de28ee
commit
99f860768c
2 changed files with 3 additions and 3 deletions
|
@ -4,6 +4,7 @@ use rustc_hir as hir;
|
|||
use rustc_lint::LateContext;
|
||||
use rustc_middle::ty::{self, Ty};
|
||||
use rustc_span::source_map::Span;
|
||||
use rustc_span::symbol::Symbol;
|
||||
|
||||
use super::INTO_ITER_ON_REF;
|
||||
|
||||
|
@ -27,7 +28,7 @@ pub(super) fn check(cx: &LateContext<'_>, expr: &hir::Expr<'_>, self_ref_ty: Ty<
|
|||
}
|
||||
}
|
||||
|
||||
fn ty_has_iter_method(cx: &LateContext<'_>, self_ref_ty: Ty<'_>) -> Option<(&'static str, &'static str)> {
|
||||
fn ty_has_iter_method(cx: &LateContext<'_>, self_ref_ty: Ty<'_>) -> Option<(Symbol, &'static str)> {
|
||||
has_iter_method(cx, self_ref_ty).map(|ty_name| {
|
||||
let mutbl = match self_ref_ty.kind() {
|
||||
ty::Ref(_, _, mutbl) => mutbl,
|
||||
|
|
|
@ -62,8 +62,7 @@ use rustc_middle::lint::in_external_macro;
|
|||
use rustc_middle::ty::{self, TraitRef, Ty, TyS};
|
||||
use rustc_semver::RustcVersion;
|
||||
use rustc_session::{declare_tool_lint, impl_lint_pass};
|
||||
use rustc_span::source_map::Span;
|
||||
use rustc_span::symbol::{sym, Symbol, SymbolStr};
|
||||
use rustc_span::symbol::{sym, SymbolStr};
|
||||
use rustc_typeck::hir_ty_to_ty;
|
||||
|
||||
use crate::utils::{
|
||||
|
|
Loading…
Reference in a new issue