Remove unused span argument from walk_fn
.
This commit is contained in:
parent
42361da5d9
commit
f6005c6b89
@ -425,7 +425,7 @@ struct UnsafeVisitor<'a, 'tcx> {
|
||||
impl<'tcx> Visitor<'tcx> for UnsafeVisitor<'_, 'tcx> {
|
||||
type NestedFilter = nested_filter::All;
|
||||
|
||||
fn visit_fn(&mut self, kind: FnKind<'tcx>, decl: &'tcx FnDecl<'_>, body_id: BodyId, span: Span, id: HirId) {
|
||||
fn visit_fn(&mut self, kind: FnKind<'tcx>, decl: &'tcx FnDecl<'_>, body_id: BodyId, _: Span, id: HirId) {
|
||||
if self.has_unsafe {
|
||||
return;
|
||||
}
|
||||
@ -438,7 +438,7 @@ impl<'tcx> Visitor<'tcx> for UnsafeVisitor<'_, 'tcx> {
|
||||
}
|
||||
}
|
||||
|
||||
walk_fn(self, kind, decl, body_id, span, id);
|
||||
walk_fn(self, kind, decl, body_id, id);
|
||||
}
|
||||
|
||||
fn visit_expr(&mut self, expr: &'tcx Expr<'_>) {
|
||||
|
@ -70,7 +70,7 @@ impl<'tcx> LateLintPass<'tcx> for UnusedAsync {
|
||||
) {
|
||||
if !span.from_expansion() && fn_kind.asyncness() == IsAsync::Async {
|
||||
let mut visitor = AsyncFnVisitor { cx, found_await: false };
|
||||
walk_fn(&mut visitor, fn_kind, fn_decl, body.id(), span, hir_id);
|
||||
walk_fn(&mut visitor, fn_kind, fn_decl, body.id(), hir_id);
|
||||
if !visitor.found_await {
|
||||
span_lint_and_help(
|
||||
cx,
|
||||
|
@ -326,6 +326,6 @@ impl<'tcx> LateLintPass<'tcx> for Unwrap {
|
||||
unwrappables: Vec::new(),
|
||||
};
|
||||
|
||||
walk_fn(&mut v, kind, decl, body.id(), span, fn_id);
|
||||
walk_fn(&mut v, kind, decl, body.id(), fn_id);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user