Skip to main content

Module solve

Module solve 

Source

Modules§

delegate 🔒
fulfill 🔒
inspect
normalize 🔒
select 🔒

Structs§

AccessedOpaques
EvalCtxt
ExternalConstraintsData
Additional constraints returned on success.
FulfillmentCtxt
A trait engine using the new trait solver.
Goal
A goal is a statement, i.e. predicate, we want to prove given some assumptions, i.e. param_env.
GoalEvaluation
The result of evaluating a goal.
GoalStalledOn
The conditions that must change for a goal to warrant
MaybeInfo
NestedNormalizationGoals
NoSolution
QueryInput
RerunNonErased
A bit like NoSolution, but for functions that normally cannot fail unless they accessed opaues. (See TypingMode::ErasedNotCoherence). Getting OpaquesAccessed doesn’t mean there truly is no solution. It just means that we want to bail out of the current query as fast as possible, possibly by returning NoSolution if that’s fastest. This is okay because when you get OpaquesAccessed we’re guaranteed that we’re going to retry this query in the original typing mode to get the correct answer.
Response

Enums§

AdtDestructorKind
Indicates that a impl Drop for Adt is const or not.
AliasBoundKind
BuiltinImplSource
CandidatePreferenceMode
Which trait candidates should be preferred over other candidates? By default, prefer where bounds over alias bounds. For marker traits, prefer alias bounds over where bounds.
CandidateSource
Possible ways the given goal can be proven.
Certainty
FetchEligibleAssocItemResponse
GenerateProofTree
GoalSource
Why a specific goal has to be proven.
HasChanged
Whether evaluating this goal ended up changing the inference state.
MaybeCause
Why we failed to evaluate a goal.
NextSolverError
NoSolutionOrRerunNonErased
OpaqueTypesJank
Supporting not-yet-defined opaque types in HIR typeck is somewhat challenging. Ideally we’d normalize them to a new inference variable and just defer type inference which relies on the opaque until we’ve constrained the hidden type.
ParamEnvSource
RerunCondition
Information about how we accessed opaque types This is what the trait solver does when each states is encountered:
RerunReason
Mainly for debugging, to keep track of the source of the rerunning in TypingMode::ErasedNotCoherence.
SizedTraitKind
Which sizedness trait - Sized, MetaSized? PointeeSized is omitted as it is removed during lowering.
SmallCopyList
StalledOnCoroutines
VisibleForLeakCheck
Whether the given region constraint should be considered/ignored for leak check. In most part of the compiler, this should be Yes, except for applying constraints from the nested goals in next-solver. Unreachable is used in places in which leak check isn’t done, e.g. borrowck.

Traits§

InferCtxtSelectExt
RerunResultExt
SolverDelegateEvalExt

Functions§

deeply_normalize
Deeply normalize all aliases in value. This does not handle inference and expects its input to be already fully resolved.
deeply_normalize_with_skipped_universes
Deeply normalize all aliases in value. This does not handle inference and expects its input to be already fully resolved.
deeply_normalize_with_skipped_universes_and_ambiguous_coroutine_goals
Deeply normalize all aliases in value. This does not handle inference and expects its input to be already fully resolved.
evaluate_root_goal_for_proof_tree_raw 🔒
evaluate_root_goal_for_proof_tree_raw_provider
Do not call this directly, use the tcx query instead.
normalize
see normalize_with_universes.
provide

Type Aliases§

CanonicalInput
CanonicalResponse
QueryResult
The result of evaluating a canonical query.
QueryResultOrRerunNonErased