[−][src]Struct rustc_mir::borrow_check::region_infer::values::RegionValueElements
Maps between a Location and a PointIndex (and vice versa).
Fields
statements_before_block: IndexVec<BasicBlock, usize>For each basic block, how many points are contained within?
basic_blocks: IndexVec<PointIndex, BasicBlock>Map backward from each point to the basic block that it belongs to.
num_points: usizeImplementations
impl RegionValueElements[src]
pub(crate) fn new(body: &Body<'_>) -> Self[src]
pub(crate) fn num_points(&self) -> usize[src]
Total number of point indices
pub(crate) fn point_from_location(&self, location: Location) -> PointIndex[src]
Converts a Location into a PointIndex. O(1).
pub(crate) fn entry_point(&self, block: BasicBlock) -> PointIndex[src]
Converts a Location into a PointIndex. O(1).
pub(crate) fn to_location(&self, index: PointIndex) -> Location[src]
Converts a PointIndex back to a location. O(1).
pub(crate) fn point_in_range(&self, index: PointIndex) -> bool[src]
Sometimes we get point-indices back from bitsets that may be out of range (because they round up to the nearest 2^N number of bits). Use this function to filter such points out if you like.
pub(crate) fn push_predecessors(
&self,
body: &Body<'_>,
index: PointIndex,
stack: &mut Vec<PointIndex>
)[src]
&self,
body: &Body<'_>,
index: PointIndex,
stack: &mut Vec<PointIndex>
)
Pushes all predecessors of index onto stack.
Auto Trait Implementations
impl RefUnwindSafe for RegionValueElements[src]
impl Send for RegionValueElements[src]
impl Sync for RegionValueElements[src]
impl Unpin for RegionValueElements[src]
impl UnwindSafe for RegionValueElements[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T[src]
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.