Skip to content

Commit a9d582f

Browse files
Speed up execution a bit by removing some walks
1 parent eb93d1b commit a9d582f

File tree

1 file changed

+21
-2
lines changed

1 file changed

+21
-2
lines changed

src/librustdoc/visit_ast.rs

+21-2
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,6 @@ impl<'a, 'tcx> RustdocVisitor<'a, 'tcx> {
250250
res,
251251
ident,
252252
is_glob,
253-
om,
254253
please_inline,
255254
) {
256255
continue;
@@ -446,6 +445,26 @@ impl<'a, 'tcx> Visitor<'tcx> for RustdocVisitor<'a, 'tcx> {
446445
}
447446

448447
fn visit_mod(&mut self, _: &hir::Mod<'tcx>, _: Span, _: hir::HirId) {
449-
// handled in `visit_item_inner`
448+
// Handled in `visit_item_inner`
449+
}
450+
451+
fn visit_use(&mut self, _: &hir::UsePath<'tcx>, _: hir::HirId) {
452+
// Handled in `visit_item_inner`
453+
}
454+
455+
fn visit_path(&mut self, _: &hir::Path<'tcx>, _: hir::HirId) {
456+
// Handled in `visit_item_inner`
457+
}
458+
459+
fn visit_label(&mut self, _: &rustc_ast::Label) {
460+
// Unneeded.
461+
}
462+
463+
fn visit_infer(&mut self, _: &hir::InferArg) {
464+
// Unneeded.
465+
}
466+
467+
fn visit_lifetime(&mut self, _: &hir::Lifetime) {
468+
// Unneeded.
450469
}
451470
}

0 commit comments

Comments
 (0)