File tree 1 file changed +6
-9
lines changed
compiler/rustc_borrowck/src/region_infer
1 file changed +6
-9
lines changed Original file line number Diff line number Diff line change @@ -385,16 +385,13 @@ fn check_opaque_type_parameter_valid(
385
385
386
386
let arg_is_param = match arg. unpack ( ) {
387
387
GenericArgKind :: Type ( ty) => matches ! ( ty. kind( ) , ty:: Param ( _) ) ,
388
- GenericArgKind :: Lifetime ( lt) => {
389
- if is_ty_alias {
390
- matches ! ( * lt, ty:: ReEarlyBound ( _) | ty:: ReFree ( _) )
391
- } else {
392
- // FIXME(#113916): we can't currently check for unique lifetime params,
393
- // see that issue for more. We will also have to ignore bivariant lifetime
394
- // params for RPIT, but that's comparatively trivial ✨
395
- continue ;
396
- }
388
+ GenericArgKind :: Lifetime ( lt) if is_ty_alias => {
389
+ matches ! ( * lt, ty:: ReEarlyBound ( _) | ty:: ReFree ( _) )
397
390
}
391
+ // FIXME(#113916): we can't currently check for unique lifetime params,
392
+ // see that issue for more. We will also have to ignore unused lifetime
393
+ // params for RPIT, but that's comparatively trivial ✨
394
+ GenericArgKind :: Lifetime ( _) => continue ,
398
395
GenericArgKind :: Const ( ct) => matches ! ( ct. kind( ) , ty:: ConstKind :: Param ( _) ) ,
399
396
} ;
400
397
You can’t perform that action at this time.
0 commit comments