Function rustc_lint::middle::ty::trait_item_of_itemUnstable
[-] [+]
[src]
pub fn trait_item_of_item(tcx: &ctxt, def_id: DefId) -> Option<ImplOrTraitItemId>
If the given def ID describes an item belonging to a trait, (either a
default method or an implementation of a trait method), return the ID of
the method inside trait definition (this means that if the given def ID
is already that of the original trait method, then the return value is
the same).
Otherwise, return None
.