ModulesΒ§
- member_
constraints π - region_
ctxt π
StructsΒ§
- Defining
Use π - ToArg
Regions πFolder - A folder to map the regions in the hidden type to their corresponding
arg_regions. - Unexpected
Hidden πRegion - Record info needed to report the same name error later.
EnumsΒ§
- Deferred
Opaque πType Error - We defer errors from [fn handle_opaque_type_uses] and only report them
if there are no
RegionErrors. If there are region errors, itβs likely that errors here are caused by them and donβt need to be handled separately.
TraitsΒ§
FunctionsΒ§
- add_
hidden_ πtype - Collect all defining uses of opaque types inside of this typeck root. This expects the hidden type to be mapped to the definition parameters of the opaque and errors if we end up with distinct hidden types.
- apply_
definition_ πsite_ hidden_ types - This function is what actually applies member constraints to the borrowck state. It is also responsible to check all uses of the opaques in their defining scope.
- clone_
and_ πresolve_ opaque_ types - We eagerly map all regions to NLL vars here, as we need to make sure weβve introduced nll vars for all used placeholders.
- collect_
defining_ πuses - compute_
definition_ πsite_ hidden_ types - This computes the actual hidden types of the opaque types and maps them to their definition sites. Outside of registering the computed hidden types this function does not mutate the current borrowck state.
- compute_
definition_ πsite_ hidden_ types_ from_ defining_ uses - detect_
opaque_ πtypes_ added_ while_ handling_ opaque_ types - In theory
apply_definition_site_hidden_typescould introduce new uses of opaque types. We do not check these new uses so this could be unsound. - handle_
unconstrained_ πhidden_ type_ errors - We handle
UnexpectedHiddenRegionerror lazily in the next solver as there may be a fully defining use in another body. - nll_
var_ πto_ universal_ region - Maps an NLL var to a deterministically chosen equal universal region.