This repository was archived by the owner on May 28, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +1
-14
lines changed
compiler/rustc_ast_lowering/src Expand file tree Collapse file tree 2 files changed +1
-14
lines changed Original file line number Diff line number Diff line change @@ -764,18 +764,7 @@ impl<'hir> LoweringContext<'_, 'hir> {
764764 & mut self ,
765765 ( index, f) : ( usize , & FieldDef ) ,
766766 ) -> hir:: FieldDef < ' hir > {
767- let ty = if let TyKind :: Path ( qself, path) = & f. ty . kind {
768- let t = self . lower_path_ty (
769- & f. ty ,
770- qself,
771- path,
772- ParamMode :: ExplicitNamed , // no `'_` in declarations (Issue #61124)
773- ImplTraitContext :: Disallowed ( ImplTraitPosition :: FieldTy ) ,
774- ) ;
775- self . arena . alloc ( t)
776- } else {
777- self . lower_ty ( & f. ty , ImplTraitContext :: Disallowed ( ImplTraitPosition :: FieldTy ) )
778- } ;
767+ let ty = self . lower_ty ( & f. ty , ImplTraitContext :: Disallowed ( ImplTraitPosition :: FieldTy ) ) ;
779768 let hir_id = self . lower_node_id ( f. id ) ;
780769 self . lower_attrs ( hir_id, & f. attrs ) ;
781770 hir:: FieldDef {
Original file line number Diff line number Diff line change @@ -481,8 +481,6 @@ pub fn lower_to_hir(tcx: TyCtxt<'_>, (): ()) -> hir::Crate<'_> {
481481enum ParamMode {
482482 /// Any path in a type context.
483483 Explicit ,
484- /// Path in a type definition, where the anonymous lifetime `'_` is not allowed.
485- ExplicitNamed ,
486484 /// The `module::Type` in `module::Type::method` in an expression.
487485 Optional ,
488486}
You can’t perform that action at this time.
0 commit comments