Struct rustc_mir::borrow_check::nll::region_infer::values::RegionValues[][src]

pub(super) struct RegionValues {
    elements: Rc<RegionValueElements>,
    matrix: SparseBitMatrix<RegionVid, RegionElementIndex>,
    causes: Option<FxHashMap<(RegionVid, RegionElementIndex), Cause>>,
}
🔬 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?

Stores the values for a set of regions. These are stored in a compact SparseBitMatrix representation, with one row per region variable. The columns consist of either universal regions or points in the CFG.

Fields

🔬 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?

🔬 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?

🔬 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?

If cause tracking is enabled, maps from a pair (r, e) consisting of a region r that contains some element e to the reason that the element is contained. There should be an entry for every bit set to 1 in SparseBitMatrix.

Methods

impl RegionValues
[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?

Creates a new set of "region values" that tracks causal information. Each of the regions in num_region_variables will be initialized with an empty set of points and no causal information.

🔬 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?

Duplicates the region values. If track_causes is false, then the resulting value will not track causal information (and any existing causal information is dropped). Otherwise, the causal information is preserved and maintained. Tracking the causal information makes region propagation significantly slower, so we prefer not to do it until an error is reported.

🔬 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?

Adds the given element to the value for the given region. Returns true if the element is newly added (i.e., was not already present).

🔬 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?

Add all elements in r_from to r_to (because e.g. r_to: r_from).

🔬 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?

Internal method to add an element to a region.

Takes a "lazy" cause -- this function will return the cause, but it will only be invoked if cause tracking is enabled.

🔬 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?

True if the region r contains the given element.

🔬 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?

True if sup_region contains all the CFG points that sub_region contains. Ignores universal regions.

🔬 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?

Iterate over the value of the region r, yielding up element indices. You may prefer universal_regions_outlived_by or elements_contained_in.

🔬 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?

Returns just the universal regions that are contained in a given region's value.

🔬 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?

Returns all the elements contained in a given region's value.

🔬 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?

Returns a "pretty" string value of the region. Meant for debugging.

🔬 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?

🔬 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?

Given a region r that contains the element elem, returns the Cause that tells us why elem is found in that region.

Returns None if cause tracking is disabled or elem is not actually found in r.

Auto Trait Implementations

impl !Send for RegionValues

impl !Sync for RegionValues