Struct rustc::ty::util::Discr [] [src]

pub struct Discr<'tcx> {
    pub val: u128,
    pub ty: Ty<'tcx>,
}
🔬 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?

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?

bit representation of the discriminant, so -128i8 is 0xFF_u128

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

Methods

impl<'tcx> Discr<'tcx>
[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?

Adds 1 to the value and wraps around if the maximum for the type is reached

🔬 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<'tcx> Copy for Discr<'tcx>
[src]

impl<'tcx> Clone for Discr<'tcx>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl<'tcx> Debug for Discr<'tcx>
[src]

Formats the value using the given formatter. Read more

impl<'tcx> Display for Discr<'tcx>
[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

impl<'tcx> !Send for Discr<'tcx>

impl<'tcx> !Sync for Discr<'tcx>