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 64a5ca5

Browse files
committedMar 19, 2024·
make type_flags(ReError) | HAS_ERROR
1 parent 094a620 commit 64a5ca5

File tree

46 files changed

+120
-626
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+120
-626
lines changed
 

‎compiler/rustc_borrowck/src/region_infer/opaque_types.rs

-4
Original file line numberDiff line numberDiff line change
@@ -378,10 +378,6 @@ fn check_opaque_type_parameter_valid(
378378
// Only check the parent generics, which will ignore any of the
379379
// duplicated lifetime args that come from reifying late-bounds.
380380
for (i, arg) in opaque_type_key.args.iter().take(parent_generics.count()).enumerate() {
381-
if let Err(guar) = arg.error_reported() {
382-
return Err(guar);
383-
}
384-
385381
let arg_is_param = match arg.unpack() {
386382
GenericArgKind::Type(ty) => matches!(ty.kind(), ty::Param(_)),
387383
GenericArgKind::Lifetime(lt) if is_ty_alias => {

‎compiler/rustc_middle/src/ty/region.rs

+1
Original file line numberDiff line numberDiff line change
@@ -251,6 +251,7 @@ impl<'tcx> Region<'tcx> {
251251
}
252252
ty::ReError(_) => {
253253
flags = flags | TypeFlags::HAS_FREE_REGIONS;
254+
flags = flags | TypeFlags::HAS_ERROR;
254255
}
255256
}
256257

0 commit comments

Comments
 (0)
Please sign in to comment.