Remove an unnecessary dtor computation and use the cached query result instead
This commit is contained in:
parent
a7b687c26e
commit
aec7739837
1 changed files with 1 additions and 1 deletions
|
@ -53,7 +53,7 @@ impl<'tcx> ConstMutationChecker<'_, 'tcx> {
|
|||
//
|
||||
// #[const_mutation_allowed]
|
||||
// pub const LOG: Log = Log { msg: "" };
|
||||
match self.tcx.calculate_dtor(def_id, |_, _| Ok(())) {
|
||||
match self.tcx.adt_destructor(def_id) {
|
||||
Some(_) => None,
|
||||
None => Some(def_id),
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue