File tree 2 files changed +12
-106
lines changed
2 files changed +12
-106
lines changed Original file line number Diff line number Diff line change @@ -1160,7 +1160,12 @@ pub fn make_normalized_projection<'tcx>(
1160
1160
) -> Option < Ty < ' tcx > > {
1161
1161
fn helper < ' tcx > ( tcx : TyCtxt < ' tcx > , param_env : ParamEnv < ' tcx > , ty : AliasTy < ' tcx > ) -> Option < Ty < ' tcx > > {
1162
1162
#[ cfg( debug_assertions) ]
1163
- if let Some ( ( i, arg) ) = ty. args . iter ( ) . enumerate ( ) . find ( |( _, arg) | arg. has_late_bound_regions ( ) ) {
1163
+ if let Some ( ( i, arg) ) = ty
1164
+ . args
1165
+ . iter ( )
1166
+ . enumerate ( )
1167
+ . find ( |( _, arg) | arg. has_escaping_bound_vars ( ) )
1168
+ {
1164
1169
debug_assert ! (
1165
1170
false ,
1166
1171
"args contain late-bound region at index `{i}` which can't be normalized.\n \
@@ -1233,7 +1238,12 @@ pub fn make_normalized_projection_with_regions<'tcx>(
1233
1238
) -> Option < Ty < ' tcx > > {
1234
1239
fn helper < ' tcx > ( tcx : TyCtxt < ' tcx > , param_env : ParamEnv < ' tcx > , ty : AliasTy < ' tcx > ) -> Option < Ty < ' tcx > > {
1235
1240
#[ cfg( debug_assertions) ]
1236
- if let Some ( ( i, arg) ) = ty. args . iter ( ) . enumerate ( ) . find ( |( _, arg) | arg. has_late_bound_regions ( ) ) {
1241
+ if let Some ( ( i, arg) ) = ty
1242
+ . args
1243
+ . iter ( )
1244
+ . enumerate ( )
1245
+ . find ( |( _, arg) | arg. has_escaping_bound_vars ( ) )
1246
+ {
1237
1247
debug_assert ! (
1238
1248
false ,
1239
1249
"args contain late-bound region at index `{i}` which can't be normalized.\n \
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments