Since 1.69.0 there is std::marker::PointerLike
, and the following 1.70.0 release also introduced std::marker::FnPtr
. However, both of them are still unstable (i.e. nightly-only and experimental).
It's also worth noting the std::fmt::Pointer
trait, because its name is very misleading, as it's actually not suitable for describing a generic pointer type.