Skip to content

Commit 9e99042

Browse files
committedSep 21, 2023
Auto merge of rust-lang#107421 - cjgillot:drop-tracking-mir, r=oli-obk
Enable -Zdrop-tracking-mir by default This PR enables the `drop-tracking-mir` flag by default. This flag was initially implemented in rust-lang#101692. This flag computes auto-traits on generators based on their analysis MIR, instead of trying to compute on the HIR body. This removes the need for HIR-based drop-tracking, as we can now reuse the same code to compute generator witness types and to compute generator interior fields.
2 parents e4a361a + 99729e4 commit 9e99042

File tree

310 files changed

+795
-8349
lines changed

Some content is hidden

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

310 files changed

+795
-8349
lines changed
 

‎compiler/rustc_codegen_ssa/src/debuginfo/type_names.rs

-1
Original file line numberDiff line numberDiff line change
@@ -426,7 +426,6 @@ fn push_debuginfo_type_name<'tcx>(
426426
| ty::Placeholder(..)
427427
| ty::Alias(..)
428428
| ty::Bound(..)
429-
| ty::GeneratorWitnessMIR(..)
430429
| ty::GeneratorWitness(..) => {
431430
bug!(
432431
"debuginfo: Trying to create type name for \

‎compiler/rustc_const_eval/src/const_eval/valtrees.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ pub(crate) fn const_to_valtree_inner<'tcx>(
152152
// FIXME(oli-obk): we can probably encode closures just like structs
153153
| ty::Closure(..)
154154
| ty::Generator(..)
155-
| ty::GeneratorWitness(..) |ty::GeneratorWitnessMIR(..)=> Err(ValTreeCreationError::NonSupportedType),
155+
| ty::GeneratorWitness(..) => Err(ValTreeCreationError::NonSupportedType),
156156
}
157157
}
158158

@@ -280,7 +280,6 @@ pub fn valtree_to_const_value<'tcx>(
280280
| ty::Closure(..)
281281
| ty::Generator(..)
282282
| ty::GeneratorWitness(..)
283-
| ty::GeneratorWitnessMIR(..)
284283
| ty::FnPtr(_)
285284
| ty::RawPtr(_)
286285
| ty::Str

0 commit comments

Comments
 (0)