Enum unrest_tmp_syn::Ty [] [src]

pub enum Ty {
    Slice(TySlice),
    Array(TyArray),
    Ptr(TyPtr),
    Rptr(TyRptr),
    BareFn(TyBareFn),
    Never(TyNever),
    Tup(TyTup),
    Path(TyPath),
    TraitObject(TyTraitObject),
    ImplTrait(TyImplTrait),
    Paren(TyParen),
    Group(TyGroup),
    Infer(TyInfer),
    Mac(Mac),
}

The different kinds of types recognized by the compiler

Variants

A variable-length array ([T])

A fixed length array ([T; n])

A raw pointer (*const T or *mut T)

A reference (&'a T or &'a mut T)

A bare function (e.g. fn(usize) -> bool)

The never type (!)

A tuple ((A, B, C, D, ...))

A path (module::module::...::Type), optionally "qualified", e.g. <Vec<T> as SomeTrait>::SomeType.

Type parameters are stored in the Path itself

A trait object type Bound1 + Bound2 + Bound3 where Bound is a trait or a lifetime.

An impl Bound1 + Bound2 + Bound3 type where Bound is a trait or a lifetime.

No-op; kept solely so that we can pretty-print faithfully

No-op: kept solely so that we can pretty-print faithfully

TyKind::Infer means the type should be inferred instead of it having been specified. This can appear anywhere in a type.

A macro in the type position.

Methods

impl Ty
[src]

Trait Implementations

impl Synom for Ty
[src]

impl Clone for Ty
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl From<TySlice> for Ty
[src]

Performs the conversion.

impl From<TyArray> for Ty
[src]

Performs the conversion.

impl From<TyPtr> for Ty
[src]

Performs the conversion.

impl From<TyRptr> for Ty
[src]

Performs the conversion.

impl From<TyBareFn> for Ty
[src]

Performs the conversion.

impl From<TyNever> for Ty
[src]

Performs the conversion.

impl From<TyTup> for Ty
[src]

Performs the conversion.

impl From<TyPath> for Ty
[src]

Performs the conversion.

impl From<TyTraitObject> for Ty
[src]

Performs the conversion.

impl From<TyImplTrait> for Ty
[src]

Performs the conversion.

impl From<TyParen> for Ty
[src]

Performs the conversion.

impl From<TyGroup> for Ty
[src]

Performs the conversion.

impl From<TyInfer> for Ty
[src]

Performs the conversion.

impl From<Mac> for Ty
[src]

Performs the conversion.

impl ToTokens for Ty
[src]

Write self to the given Tokens. Read more

Convert self directly into a Tokens object. Read more