@@ -170,14 +170,14 @@ impl Qualif for NeedsNonConstDrop {
170170
171171 #[ instrument( level = "trace" , skip( cx) , ret) ]
172172 fn in_any_value_of_ty < ' tcx > ( cx : & ConstCx < ' _ , ' tcx > , ty : Ty < ' tcx > ) -> bool {
173- // If this doesn't need drop at all, then don't select `~ const Destruct`.
173+ // If this doesn't need drop at all, then don't select `[ const] Destruct`.
174174 if !ty. needs_drop ( cx. tcx , cx. typing_env ) {
175175 return false ;
176176 }
177177
178- // We check that the type is `~ const Destruct` since that will verify that
179- // the type is both `~ const Drop` (if a drop impl exists for the adt), *and*
180- // that the components of this type are also `~ const Destruct`. This
178+ // We check that the type is `[ const] Destruct` since that will verify that
179+ // the type is both `[ const] Drop` (if a drop impl exists for the adt), *and*
180+ // that the components of this type are also `[ const] Destruct`. This
181181 // amounts to verifying that there are no values in this ADT that may have
182182 // a non-const drop.
183183 let destruct_def_id = cx. tcx . require_lang_item ( LangItem :: Destruct , cx. body . span ) ;
@@ -203,9 +203,9 @@ impl Qualif for NeedsNonConstDrop {
203203 fn is_structural_in_adt_value < ' tcx > ( cx : & ConstCx < ' _ , ' tcx > , adt : AdtDef < ' tcx > ) -> bool {
204204 // As soon as an ADT has a destructor, then the drop becomes non-structural
205205 // in its value since:
206- // 1. The destructor may have `~ const` bounds which are not present on the type.
206+ // 1. The destructor may have `[ const] ` bounds which are not present on the type.
207207 // Someone needs to check that those are satisfied.
208- // While this could be instead satisfied by checking that the `~ const Drop`
208+ // While this could be instead satisfied by checking that the `[ const] Drop`
209209 // impl holds (i.e. replicating part of the `in_any_value_of_ty` logic above),
210210 // even in this case, we have another problem, which is,
211211 // 2. The destructor may *modify* the operand being dropped, so even if we
0 commit comments