fmt
This commit is contained in:
parent
f6f5180d5f
commit
48a3ba9a33
2 changed files with 6 additions and 4 deletions
|
@ -990,8 +990,10 @@ impl Visitor<'tcx> for Checker<'mir, 'tcx> {
|
|||
|
||||
// Check to see if the type of this place can ever have a drop impl. If not, this
|
||||
// `Drop` terminator is frivolous.
|
||||
let ty_needs_drop =
|
||||
dropped_place.ty(self.body, self.tcx).ty.needs_non_const_drop(self.tcx, self.param_env);
|
||||
let ty_needs_drop = dropped_place
|
||||
.ty(self.body, self.tcx)
|
||||
.ty
|
||||
.needs_non_const_drop(self.tcx, self.param_env);
|
||||
|
||||
if !ty_needs_drop {
|
||||
return;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue