Function rustc::middle::ty::named_element_tyUnstable [-] [+] [src]

pub fn named_element_ty<'tcx>(cx: &ctxt<'tcx>, ty: Ty<'tcx>, n: Name, variant: Option<DefId>) -> Option<Ty<'tcx>>

Returns the type of element at field n in struct or struct-like type t. For an enum t, variant must be some def id.