Skip to content

Commit 27c958f

Browse files
committed
Review comments.
1 parent d804ef8 commit 27c958f

File tree

4 files changed

+2
-158
lines changed

4 files changed

+2
-158
lines changed

compiler/rustc_ast_lowering/src/lifetime_collector.rs

-151
This file was deleted.

compiler/rustc_hir/src/hir.rs

-5
Original file line numberDiff line numberDiff line change
@@ -2849,11 +2849,6 @@ pub enum TyKind<'hir> {
28492849
/// Type parameters may be stored in each `PathSegment`.
28502850
Path(QPath<'hir>),
28512851
/// An opaque type definition itself. This is only used for `impl Trait`.
2852-
///
2853-
/// The generic argument list contains the lifetimes (and in the future
2854-
/// possibly parameters) that are actually bound on the `impl Trait`.
2855-
///
2856-
/// The last parameter specifies whether this opaque appears in a trait definition.
28572852
OpaqueDef(&'hir OpaqueTy<'hir>),
28582853
/// A trait object type `Bound1 + Bound2 + Bound3`
28592854
/// where `Bound` is a trait or a lifetime.

compiler/rustc_hir_analysis/src/collect/resolve_bound_vars.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ enum Scope<'a> {
156156
/// `fn foo<'a>() -> impl MyTrait<'a> { ... }`
157157
///
158158
/// HIR tells us that `'a` refer to the lifetime bound on `foo`.
159-
/// However, typeck and borrowck for opaques are work based on using a new generics type.
159+
/// However, typeck and borrowck for opaques work based on using a new generic type.
160160
/// `type MyAnonTy<'b> = impl MyTrait<'b>;`
161161
///
162162
/// This scope collects the mapping `'a -> 'b`.

compiler/rustc_resolve/src/late.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -841,7 +841,7 @@ impl<'ra: 'ast, 'ast, 'tcx> Visitor<'ast> for LateResolutionVisitor<'_, 'ast, 'r
841841
self.r.record_partial_res(ty.id, PartialRes::new(res));
842842
visit::walk_ty(self, ty)
843843
}
844-
TyKind::ImplTrait(_, _) => {
844+
TyKind::ImplTrait(..) => {
845845
let candidates = self.lifetime_elision_candidates.take();
846846
visit::walk_ty(self, ty);
847847
self.lifetime_elision_candidates = candidates;

0 commit comments

Comments
 (0)