# Function rustc_monomorphize::collector::collect_items_of_instance

source ·

    fn collect_items_of_instance<'tcx>(
        tcx: TyCtxt<'tcx>,
        instance: Instance<'tcx>,
        used_items: &mut Vec<Spanned<MonoItem<'tcx>>>,
        mentioned_items: &mut Vec<Spanned<MonoItem<'tcx>>>,
        mode: CollectionMode,
    )

Expand description

Scans the MIR in order to find function calls, closures, and drop-glue.

Anything that’s found is added to `output`. Furthermore the “mentioned items” of the MIR are returned.