Struct rustc::middle::region::BlockRemainder [−][src]
pub struct BlockRemainder {
pub block: ItemLocalId,
pub first_statement_index: FirstStatementIndex,
}🔬 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?
Represents a subscope of block for a binding that is introduced
by block.stmts[first_statement_index]. Such subscopes represent
a suffix of the block. Note that each subscope does not include
the initializer expression, if any, for the statement indexed by
first_statement_index.
For example, given { let (a, b) = EXPR_1; let c = EXPR_2; ... }:
-
the subscope with
first_statement_index == 0is scope of bothaandb; it does not include EXPR_1, but does include everything after that firstlet. (If you want a scope that includes EXPR_1 as well, then do not useScope::Remainder, but instead anotherScopethat encompasses the whole block, e.g.Scope::Node. -
the subscope with
first_statement_index == 1is scope ofc, and thus does not include EXPR_2, but covers the....
Fields
block: ItemLocalId
🔬 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?
first_statement_index: FirstStatementIndex
🔬 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?
Trait Implementations
impl<'a, 'tcx> HashStable<StableHashingContext<'a>> for BlockRemainder[src]
impl<'a, 'tcx> HashStable<StableHashingContext<'a>> for BlockRemainderfn hash_stable<W: StableHasherResult>(
&self,
__ctx: &mut StableHashingContext<'a>,
__hasher: &mut StableHasher<W>
)[src]
fn hash_stable<W: StableHasherResult>(
&self,
__ctx: &mut StableHashingContext<'a>,
__hasher: &mut StableHasher<W>
)🔬 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?
impl Clone for BlockRemainder[src]
impl Clone for BlockRemainderfn clone(&self) -> BlockRemainder[src]
fn clone(&self) -> BlockRemainderReturns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
fn clone_from(&mut self, source: &Self)Performs copy-assignment from source. Read more
impl PartialEq for BlockRemainder[src]
impl PartialEq for BlockRemainderfn eq(&self, other: &BlockRemainder) -> bool[src]
fn eq(&self, other: &BlockRemainder) -> boolThis method tests for self and other values to be equal, and is used by ==. Read more
fn ne(&self, other: &BlockRemainder) -> bool[src]
fn ne(&self, other: &BlockRemainder) -> boolThis method tests for !=.
impl PartialOrd for BlockRemainder[src]
impl PartialOrd for BlockRemainderfn partial_cmp(&self, other: &BlockRemainder) -> Option<Ordering>[src]
fn partial_cmp(&self, other: &BlockRemainder) -> Option<Ordering>This method returns an ordering between self and other values if one exists. Read more
fn lt(&self, other: &BlockRemainder) -> bool[src]
fn lt(&self, other: &BlockRemainder) -> boolThis method tests less than (for self and other) and is used by the < operator. Read more
fn le(&self, other: &BlockRemainder) -> bool[src]
fn le(&self, other: &BlockRemainder) -> boolThis method tests less than or equal to (for self and other) and is used by the <= operator. Read more
fn gt(&self, other: &BlockRemainder) -> bool[src]
fn gt(&self, other: &BlockRemainder) -> boolThis method tests greater than (for self and other) and is used by the > operator. Read more
fn ge(&self, other: &BlockRemainder) -> bool[src]
fn ge(&self, other: &BlockRemainder) -> boolThis method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
impl Eq for BlockRemainder[src]
impl Eq for BlockRemainderfn assert_receiver_is_total_eq(&self)[src]
fn assert_receiver_is_total_eq(&self)impl Ord for BlockRemainder[src]
impl Ord for BlockRemainderfn cmp(&self, other: &BlockRemainder) -> Ordering[src]
fn cmp(&self, other: &BlockRemainder) -> OrderingThis method returns an Ordering between self and other. Read more
fn max(self, other: Self) -> Self1.21.0[src]
fn max(self, other: Self) -> SelfCompares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self1.21.0[src]
fn min(self, other: Self) -> SelfCompares and returns the minimum of two values. Read more
impl Hash for BlockRemainder[src]
impl Hash for BlockRemainderfn hash<__H: Hasher>(&self, state: &mut __H)[src]
fn hash<__H: Hasher>(&self, state: &mut __H)Feeds this value into the given [Hasher]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher, 1.3.0[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher, Feeds a slice of this type into the given [Hasher]. Read more
impl Encodable for BlockRemainder[src]
impl Encodable for BlockRemainderfn encode<__S: Encoder>(&self, s: &mut __S) -> Result<(), __S::Error>[src]
fn encode<__S: Encoder>(&self, s: &mut __S) -> Result<(), __S::Error>🔬 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?
impl Decodable for BlockRemainder[src]
impl Decodable for BlockRemainderfn decode<__D: Decoder>(d: &mut __D) -> Result<BlockRemainder, __D::Error>[src]
fn decode<__D: Decoder>(d: &mut __D) -> Result<BlockRemainder, __D::Error>🔬 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?
impl Debug for BlockRemainder[src]
impl Debug for BlockRemainderfn fmt(&self, f: &mut Formatter) -> Result[src]
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl Copy for BlockRemainder[src]
impl Copy for BlockRemainderAuto Trait Implementations
impl Send for BlockRemainder
impl Send for BlockRemainderimpl Sync for BlockRemainder
impl Sync for BlockRemainder