Expand description
Candidate selection. See the rustc dev guide for more information on how this works.
Modules§
- _match 🔒
- candidate_
assembly 🔒 - Candidate assembly.
- confirmation 🔒
- Confirmation.
Structs§
- Evaluated
Candidate 🔒 - Provisional
Evaluation 🔒 - A cache value for the provisional cache: contains the depth-first number (DFN) and result.
- Provisional
Evaluation 🔒Cache - The “provisional evaluation cache” is used to store intermediate cache results when solving auto traits. Auto traits are unusual in that they can support cycles. So, for example, a “proof tree” like this would be ok:
- Selection
Candidate 🔒Set - Selection
Context - Trait
Obligation 🔒Stack - Trait
Obligation 🔒Stack List
Enums§
- Builtin
Impl 🔒Conditions - When does the builtin impl for
T: Trait
apply? - Evaluation
Result - The result of trait evaluation. The order is important here as the evaluation of a list is the maximum of the evaluations.
- Intercrate
Ambiguity Cause - Overflow
Error - Indicates that trait evaluation caused overflow and in which pass.
- Projection
Matches 🔒Projection - Selection
Candidate - The selection process begins by considering all impls, where
clauses, and so forth that might resolve an obligation. Sometimes
we’ll be able to say definitively that (e.g.) an impl does not
apply to the obligation: perhaps it is defined for
usize
but the obligation is fori32
. In that case, we drop the impl out of the list. But the other cases are considered candidates.
Functions§
- bind_
coroutine_ 🔒hidden_ types_ above - Replace all regions inside the coroutine interior with late bound regions. Note that each region slot in the types gets a new fresh late bound region, which means that none of the regions inside relate to any other, even if typeck had previously found constraints that would cause them to be related.