Location
|
/// Only permitted in cleanup blocks. `Resume` is not permitted with `-C unwind=abort` after |
|
/// deaggregation runs. |
|
UnwindResume, |
|
/// Disallowed after deaggregation for all aggregate kinds except `Array` and `Coroutine`. After |
|
/// coroutine lowering, `Coroutine` aggregate kinds are disallowed too. |
|
Aggregate(Box<AggregateKind<'tcx>>, IndexVec<FieldIdx, Operand<'tcx>>), |
|
/// * [`Rvalue::Aggregate`] for any `AggregateKind` except `Array` |
|
/// Disallowed after deaggregation for all aggregate kinds except `Array` and `Coroutine`. After |
|
/// coroutine lowering, `Coroutine` aggregate kinds are disallowed too. |
|
Aggregate(AggregateKind, Vec<Operand>), |
|
self.fail(location, "`SetDiscriminant`is not allowed until deaggregation"); |
|
self.fail(location, "`Deinit`is not allowed until deaggregation"); |
|
self.fail(location, "`SetDiscriminant`is not allowed until deaggregation"); |
|
self.fail(location, "`Deinit`is not allowed until deaggregation"); |
|
/// Disallowed after deaggregation for all aggregate kinds except `Array` and `Coroutine`. After |
Summary
I was reading the comments in rustc_middle::mir::syntax, and I found that the comments on rustc_middle::mir::syntax::Rvalue::Aggregate is weird.
/// Disallowed after deaggregation for all aggregate kinds except `Array` and `Coroutine`. After
/// coroutine lowering, `Coroutine` aggregate kinds are disallowed too.
Aggregate(Box<AggregateKind<'tcx>>, IndexVec<FieldIdx, Operand<'tcx>>)
Because I have observed Aggregate Rvalue in optimized MIR.
Then I found a pr "Do not deaggregate MIR #107267" stated that deaggregation have been removed from general compiling progress, such that these relevant comments about deaggregation is outdated.
So I think these pieces of comments should be deleted.
Location
rust/compiler/rustc_middle/src/mir/syntax.rs
Lines 722 to 724 in e0883a2
rust/compiler/rustc_middle/src/mir/syntax.rs
Lines 1442 to 1444 in e0883a2
rust/compiler/rustc_middle/src/mir/syntax.rs
Line 130 in e0883a2
rust/compiler/stable_mir/src/mir/body.rs
Lines 486 to 488 in e0883a2
rust/compiler/rustc_mir_transform/src/validate.rs
Line 313 in e0883a2
rust/compiler/rustc_mir_transform/src/validate.rs
Line 318 in e0883a2
rust/compiler/rustc_mir_transform/src/validate.rs
Line 1504 in e0883a2
rust/compiler/rustc_mir_transform/src/validate.rs
Line 1521 in e0883a2
rust/src/tools/rust-analyzer/crates/hir-ty/src/mir.rs
Line 450 in e0883a2
rust/src/tools/rust-analyzer/crates/hir-ty/src/mir.rs
Line 978 in e0883a2
Summary
I was reading the comments in rustc_middle::mir::syntax, and I found that the comments on rustc_middle::mir::syntax::Rvalue::Aggregate is weird.
Because I have observed
AggregateRvaluein optimized MIR.Then I found a pr "Do not deaggregate MIR #107267" stated that deaggregation have been removed from general compiling progress, such that these relevant comments about deaggregation is outdated.
So I think these pieces of comments should be deleted.