Enum rustc::hir::Item_ [] [src]

pub enum Item_ {
    ItemExternCrate(Option<Name>),
    ItemUse(P<Path>, UseKind),
    ItemStatic(P<Ty>, MutabilityBodyId),
    ItemConst(P<Ty>, BodyId),
    ItemFn(P<FnDecl>, UnsafetyConstnessAbiGenericsBodyId),
    ItemMod(Mod),
    ItemForeignMod(ForeignMod),
    ItemGlobalAsm(P<GlobalAsm>),
    ItemTy(P<Ty>, Generics),
    ItemEnum(EnumDefGenerics),
    ItemStruct(VariantDataGenerics),
    ItemUnion(VariantDataGenerics),
    ItemTrait(IsAutoUnsafetyGenericsTyParamBoundsHirVec<TraitItemRef>),
    ItemTraitAlias(GenericsTyParamBounds),
    ItemImpl(UnsafetyImplPolarityDefaultnessGenericsOption<TraitRef>, P<Ty>, HirVec<ImplItemRef>),
}
🔬 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?

Variants

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

An extern crate item, with optional original crate name if the crate was renamed.

E.g. extern crate foo or extern crate foo_bar as foo

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

use foo::bar::*; or use foo::bar::baz as quux;

or just

use foo::bar::baz; (with as baz implicitly on the right)

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

A static item

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

A const item

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

A function declaration

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

A module

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

An external module

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

Module-level inline assembly (from global_asm!)

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

A type alias, e.g. type Foo = Bar<u8>

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

An enum definition, e.g. enum Foo<A, B> {C<A>, D<B>}

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

A struct definition, e.g. struct Foo<A> {x: A}

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

A union definition, e.g. union Foo<A, B> {x: A, y: B}

🔬 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 Trait Declaration

🔬 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 Trait Alias Declaration

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

An implementation, eg impl<A> Trait for Foo { .. }

Methods

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

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

Trait Implementations

impl Clone for Item_
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl PartialEq for Item_
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Eq for Item_
[src]

impl Encodable for Item_
[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?

impl Decodable for Item_
[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?

impl Hash for Item_
[src]

Feeds this value into the given [Hasher]. Read more

Feeds a slice of this type into the given [Hasher]. Read more

impl Debug for Item_
[src]

Formats the value using the given formatter. Read more

impl<'a, 'tcx> HashStable<StableHashingContext<'a>> for Item_
[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?

Auto Trait Implementations

impl !Send for Item_

impl !Sync for Item_