Expand description
This module contains methods that assist in checking that impls are general enough, i.e. that they always apply to every valid instantaiton of the ADT theyβre implemented for.
This is necessary for Drop and negative impls to be well-formed.
FunctionsΒ§
- check_
drop_ πimpl - This function confirms that the
Dropimplementation identified bydrop_impl_didis not any more specialized than the type it is attached to (Issue #8142). - check_
drop_ πxor_ pin_ drop - This function checks at least and at most one of
Drop::dropandDrop::pin_dropis implemented. It also checks thatDrop::pin_dropmust be implemented if#[pin_v2]is present on the type. - check_
negative_ πauto_ trait_ impl - ensure_
all_ πfields_ are_ const_ destruct - ensure_
impl_ πparams_ and_ item_ params_ correspond - ensure_
impl_ πpredicates_ are_ implied_ by_ item_ defn - Confirms that all predicates defined on the
Dropimpl (drop_impl_def_id) are able to be proven from withinadt_def_idβs environment. I.e. all the predicates on the impl are implied by the ADT being well formed.