clippy_utils::ty

Function peel_mid_ty_refs_is_mutable

source
pub fn peel_mid_ty_refs_is_mutable(ty: Ty<'_>) -> (Ty<'_>, usize, Mutability)
Expand description

Peels off all references on the type. Returns the underlying type, the number of references removed, and whether the pointer is ultimately mutable or not.