Skip to content

Commit 75558b2

Browse files
committed
Remove unused StaticLifetimeVisitor.
1 parent 092a284 commit 75558b2

File tree

1 file changed

+0
-12
lines changed

1 file changed

+0
-12
lines changed

Diff for: compiler/rustc_middle/src/ty/diagnostics.rs

-12
Original file line numberDiff line numberDiff line change
@@ -592,18 +592,6 @@ impl<'v> hir::intravisit::Visitor<'v> for TraitObjectVisitor<'v> {
592592
}
593593
}
594594

595-
/// Collect al types that have an implicit `'static` obligation that we could suggest `'_` for.
596-
pub struct StaticLifetimeVisitor<'tcx>(pub Vec<Span>, pub crate::hir::map::Map<'tcx>);
597-
598-
impl<'v> hir::intravisit::Visitor<'v> for StaticLifetimeVisitor<'v> {
599-
fn visit_lifetime(&mut self, lt: &'v hir::Lifetime) {
600-
if let hir::LifetimeName::ImplicitObjectLifetimeDefault | hir::LifetimeName::Static = lt.res
601-
{
602-
self.0.push(lt.ident.span);
603-
}
604-
}
605-
}
606-
607595
pub struct IsSuggestableVisitor<'tcx> {
608596
tcx: TyCtxt<'tcx>,
609597
infer_suggestable: bool,

0 commit comments

Comments
 (0)