pub fn elaborate_drop<'b, 'tcx, D>(
elaborator: &mut D,
D: DropElaborator<'b, 'tcx>,
“Elaborates” a drop of
path and patches
bb’s terminator to execute it.
elaborator is used to determine what should happen at the drop terminator. It
decides whether the drop can be statically determined or whether it needs a dynamic drop flag,
and whether the drop is “open”, ie. should be expanded to drop all subfields of the dropped
When this returns, the MIR patch in the
elaborator contains the necessary changes.