ModulesΒ§
- errors π
StructsΒ§
- Checker π
- Inherited π
- Fields shared by the top-level function and its nested closure/generators
- Refine
Mode π - Resolved
Call π - Shape
Mode π - Shape
Result π - The result of running the shape phase.
- Skip
Constr π
EnumsΒ§
- Guard π
- A
Guarddescribes extra βcontrolβ information that holds at the start of a successor basic block - SubFn
SubFnlets us reuse most of the same code forcheck_fn_subtypingfor both the case where we have an early-bound function signature (e.g., for a trait method???) and versions without, e.g. a plain closure against its FnTraitPredicate obligation.
TraitsΒ§
- Mode π
FunctionsΒ§
- all_
predicates_ πof - bool_
int_ πcast - bool_
uint_ πcast - char_
uint_ πcast - check_
fn_ πsubtyping - The function
check_fn_subtypingdoes a function subtyping check between the sub-type (T_f) corresponding to the type ofdef_id@argsand the super-type (T_g) corresponding to theoblig_sig. This subtyping is handled as akin to the code - collect_
params_ πin_ clauses - find_
trait_ πitem - fold_
local_ πptrs - Fold local pointers implements roughly a rule like the following (for all local pointers)
that converts the local pointers created via
unfold_local_ptrsback into&mut. - guarded_
uint_ πty - infer_
under_ πmut_ ref_ hack - HACK(nilehmann) This let us infer parameters under mutable references for the simple case
where the formal argument is of the form
&mut B[@n], e.g., the type of the first argument toRVec::get_mutis&mut RVec<T>[@n]. We should remove this after we implement opening of mutable references. - instantiate_
args_ πfor_ constructor - instantiate_
args_ πfor_ fun_ call - int_
bit_ πwidth - int_
int_ πcast - is_
indexed_ πmut_ skipping_ constr - marker_
at_ πdominator - promoted_
fn_ πsig - trait_
impl_ πsubtyping - Trait subtyping check, which makes sure that the type for an impl method (def_id) is a subtype of the corresponding trait method.
- uint_
bit_ πwidth - uint_
char_ πcast - Unlike
char_uint_castrust only allowsu8tocharcasts, which are non-lossy, so we can use indexed type directly. - uint_
int_ πcast - uint_
uint_ πcast - unfold_
local_ πptrs - Temporarily (around a function call) convert an
&mutto an&strgto allow for the call to be checked. This is done by unfolding the&mutinto a local pointer at the call-site and then folding the pointer back into the&mutupon return. See alsofold_local_ptrs.
Type AliasesΒ§
- Result π