File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -51,13 +51,14 @@ the [`mir_borrowck`] query.
51
51
the purpose of this type check is to determine all of the constraints between
52
52
different regions.
53
53
- Next, we do [ region inference] ( borrow_check/region_inference.html ) , which computes
54
- the values of each region — basically, points in the control-flow graph.
54
+ the values of each region — basically, the points in the control-flow graph where
55
+ each lifetime must be valid according to the constraints we collected.
55
56
- At this point, we can compute the "borrows in scope" at each point.
56
57
- Finally, we do a second walk over the MIR, looking at the actions it
57
58
does and reporting errors. For example, if we see a statement like
58
59
` *a + 1 ` , then we would check that the variable ` a ` is initialized
59
60
and that it is not mutably borrowed, as either of those would
60
- require an error to be reported.
61
- - Doing this check requires the results of all the previous analyses.
61
+ require an error to be reported. Doing this check requires the results of all
62
+ the previous analyses.
62
63
63
64
[ `replace_regions_in_mir` ] : https://doc.rust-lang.org/nightly/nightly-rustc/rustc_mir/borrow_check/nll/fn.replace_regions_in_mir.html
You can’t perform that action at this time.
0 commit comments