Module rustc_mir::borrow_check::nll::region_infer::dfs[][src]

🔬 This is a nightly-only experimental API. (rustc_private)

this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?

Module defining the dfs method on RegionInferenceContext, along with its associated helper traits.

Re-exports

use borrow_check::nll::universal_regions::UniversalRegions;
use borrow_check::nll::region_infer::RegionInferenceContext;
use borrow_check::nll::region_infer::values::RegionElementIndex;
use borrow_check::nll::region_infer::values::RegionValueElements;
use borrow_check::nll::region_infer::values::RegionValues;
use syntax::codemap::Span;
use rustc::mir::Location;
use rustc::mir::Mir;
use rustc::ty::RegionVid;
use rustc_data_structures::bitvec::BitVector;
use rustc_data_structures::indexed_vec::Idx;

Structs

CopyFromSourceToTarget [
Experimental
]

Used during inference to enforce a R1: R2 @ P constraint. For each point Q we reach along the DFS, we check if Q is in R2 (the "source region"). If not, we stop the walk. Otherwise, we add Q to R1 (the "target region") and continue to Q's successors. If we reach the end of the graph, then we add any universal regions from R2 into R1.

DfsStorage [
Experimental
]
TestTargetOutlivesSource [
Experimental
]

Used after inference to test a R1: R2 @ P constraint. For each point Q we reach along the DFS, we check if Q in R2 is also contained in R1. If not, we abort the walk early with an Err condition. Similarly, if we reach the end of the graph and find that R1 contains some universal region that R2 does not contain, we abort the walk early.

Traits

DfsOp [
Experimental
]

Customizes the operation of the dfs function. This function is used during inference to satisfy a R1: R2 @ P constraint.