Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit d2e0d11

Browse files
committedAug 18, 2024
elided_named_lifetimes: allow elided 'static in assoc consts's types
1 parent c726445 commit d2e0d11

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed
 

‎compiler/rustc_resolve/src/late.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -2978,7 +2978,7 @@ impl<'a: 'ast, 'b, 'ast, 'tcx> LateResolutionVisitor<'a, 'b, 'ast, 'tcx> {
29782978
},
29792979
|this| {
29802980
this.visit_generics(generics);
2981-
this.visit_ty(ty);
2981+
this.visit_ty_do_not_warn_elided_static(ty);
29822982

29832983
// Only impose the restrictions of `ConstRibKind` for an
29842984
// actual constant expression in a provided default.
@@ -3191,7 +3191,7 @@ impl<'a: 'ast, 'b, 'ast, 'tcx> LateResolutionVisitor<'a, 'b, 'ast, 'tcx> {
31913191
);
31923192

31933193
this.visit_generics(generics);
3194-
this.visit_ty(ty);
3194+
this.visit_ty_do_not_warn_elided_static(ty);
31953195
if let Some(expr) = expr {
31963196
// We allow arbitrary const expressions inside of associated consts,
31973197
// even if they are potentially not const evaluatable.

0 commit comments

Comments
 (0)
Failed to load comments.