Enum rustc_typeck::check::Diverges [−][src]
pub enum Diverges { Maybe, Always, WarnedAlways, }
🔬 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?
Tracks whether executing a node may exit normally (versus return/break/panic, which "diverge", leaving dead code in their wake). Tracked semi-automatically (through type variables marked as diverging), with some manual adjustments for control-flow primitives (approximating a CFG).
Variants
Maybe
🔬 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?
Potentially unknown, some cases converge, others require a CFG to determine them.
Always
🔬 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?
Definitely known to diverge and therefore not reach the next sibling or its parent.
WarnedAlways
🔬 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?
Same as Always
but with a reachability
warning already emitted
Methods
impl Diverges
[src]
impl Diverges
fn always(self) -> bool
[src]
fn always(self) -> bool
🔬 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 Copy for Diverges
[src]
impl Copy for Diverges
impl Clone for Diverges
[src]
impl Clone for Diverges
fn clone(&self) -> Diverges
[src]
fn clone(&self) -> Diverges
Returns 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 Debug for Diverges
[src]
impl Debug for Diverges
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl PartialEq for Diverges
[src]
impl PartialEq for Diverges
fn eq(&self, other: &Diverges) -> bool
[src]
fn eq(&self, other: &Diverges) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
#[must_use]
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl Eq for Diverges
[src]
impl Eq for Diverges
fn assert_receiver_is_total_eq(&self)
[src]
fn assert_receiver_is_total_eq(&self)
impl PartialOrd for Diverges
[src]
impl PartialOrd for Diverges
fn partial_cmp(&self, other: &Diverges) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &Diverges) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
#[must_use]
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
#[must_use]
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
#[must_use]
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
#[must_use]
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Ord for Diverges
[src]
impl Ord for Diverges
fn cmp(&self, other: &Diverges) -> Ordering
[src]
fn cmp(&self, other: &Diverges) -> Ordering
This method returns an Ordering
between self
and other
. Read more
fn max(self, other: Self) -> Self
1.21.0[src]
fn max(self, other: Self) -> Self
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
fn min(self, other: Self) -> Self
Compares and returns the minimum of two values. Read more
impl BitAnd for Diverges
[src]
impl BitAnd for Diverges
type Output = Self
The resulting type after applying the &
operator.
fn bitand(self, other: Self) -> Self
[src]
fn bitand(self, other: Self) -> Self
Performs the &
operation.
impl BitOr for Diverges
[src]
impl BitOr for Diverges
type Output = Self
The resulting type after applying the |
operator.
fn bitor(self, other: Self) -> Self
[src]
fn bitor(self, other: Self) -> Self
Performs the |
operation.
impl BitAndAssign for Diverges
[src]
impl BitAndAssign for Diverges
fn bitand_assign(&mut self, other: Self)
[src]
fn bitand_assign(&mut self, other: Self)
Performs the &=
operation.
impl BitOrAssign for Diverges
[src]
impl BitOrAssign for Diverges
fn bitor_assign(&mut self, other: Self)
[src]
fn bitor_assign(&mut self, other: Self)
Performs the |=
operation.