Module coherence

Source
Expand description

See Rustc Dev Guide chapters on trait-resolution and trait-specialization for more info on how this works.

Structs§

AmbiguityCausesVisitor 🔒
OverlapResult
UncoveredTyParams

Enums§

Conflict
InCrate
Whether we do the orphan check relative to this crate or to some remote crate.
IntersectionHasImpossibleObligations 🔒
The result of [fn impl_intersection_has_impossible_obligation].
IsFirstInputType
OrphanCheckErr
OrphanCheckMode
TrackAmbiguityCauses 🔒

Functions§

add_placeholder_note
compute_intercrate_ambiguity_causes 🔒
Compute the intercrate_ambiguity_causes for the new solver using “proof trees”.
equate_impl_headers 🔒
fresh_impl_header 🔒
fresh_impl_header_normalized 🔒
impl_intersection_has_impossible_obligation 🔒
Check if both impls can be satisfied by a common type by considering whether any of either impl’s obligations is not known to hold.
impl_intersection_has_negative_obligation 🔒
Check if both impls can be satisfied by a common type by considering whether any of first impl’s obligations is known not to hold via a negative predicate.
orphan_check_trait_ref
Checks whether a trait-ref is potentially implementable by a crate.
overlap 🔒
Can both impl a and impl b be satisfied by a common type (including where-clauses)? If so, returns an ImplHeader that unifies the two impls.
overlapping_impls
If there are types that satisfy both impls, returns Some with a suitably-freshened ImplHeader with those types instantiated. Otherwise, returns None.
plug_infer_with_placeholders 🔒
search_ambiguity_causes 🔒
suggest_increasing_recursion_limit 🔒
trait_ref_is_knowable
Returns whether all impls which would apply to the trait_ref e.g. Ty: Trait<Arg> are already known in the local crate.
trait_ref_is_local_or_fundamental
try_prove_negated_where_clause 🔒