File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
src/librustc_mir/transform Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -509,7 +509,10 @@ impl Qualif for IsNotPromotable {
509509}
510510
511511/// Refers to temporaries which cannot be promoted *implicitly*.
512- /// Explicit promotion e.g. for constant arguments declared via `rustc_args_required_const`.
512+ /// Explicit promotion e.g. for constant arguments declared via `rustc_args_required_const` or by
513+ /// happening inside a constant, static or const fn. Inside a const context all constness rules
514+ /// apply, so implicit promotion simply has to follow the regular constant rules (modulo interior
515+ /// mutability or `Drop` rules which are handled `HasMutInterior` and `NeedsDrop` respectively)
513516struct IsNotImplicitlyPromotable ;
514517
515518impl Qualif for IsNotImplicitlyPromotable {
You can’t perform that action at this time.
0 commit comments