proc_quote

Trait ToTokens

Source
pub trait ToTokens {
    // Required method
    fn to_tokens(&self, tokens: &mut TokenStream);

    // Provided methods
    fn to_token_stream(&self) -> TokenStream { ... }
    fn into_token_stream(self) -> TokenStream
       where Self: Sized { ... }
}
Expand description

Types that can be interpolated inside a quote! invocation.

Required Methods§

Source

fn to_tokens(&self, tokens: &mut TokenStream)

Write self to the given TokenStream.

The token append methods provided by the TokenStreamExt extension trait may be useful for implementing ToTokens.

§Example

Example implementation for a struct representing Rust paths like std::cmp::PartialEq:

use proc_macro2::{TokenTree, Spacing, Span, Punct, TokenStream};
use quote::{TokenStreamExt, ToTokens};

pub struct Path {
    pub global: bool,
    pub segments: Vec<PathSegment>,
}

impl ToTokens for Path {
    fn to_tokens(&self, tokens: &mut TokenStream) {
        for (i, segment) in self.segments.iter().enumerate() {
            if i > 0 || self.global {
                // Double colon `::`
                tokens.append(Punct::new(':', Spacing::Joint));
                tokens.append(Punct::new(':', Spacing::Alone));
            }
            segment.to_tokens(tokens);
        }
    }
}

Provided Methods§

Source

fn to_token_stream(&self) -> TokenStream

Convert self directly into a TokenStream object.

This method is implicitly implemented using to_tokens, and acts as a convenience method for consumers of the ToTokens trait.

Source

fn into_token_stream(self) -> TokenStream
where Self: Sized,

Convert self directly into a TokenStream object.

This method is implicitly implemented using to_tokens, and acts as a convenience method for consumers of the ToTokens trait.

Implementations on Foreign Types§

Source§

impl ToTokens for TokenTree

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Meta

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for NestedMeta

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Fields

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Visibility

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Expr

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Member

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for GenericParam

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TraitBoundModifier

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypeParamBound

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for WherePredicate

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Lit

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for BinOp

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for UnOp

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for GenericArgument

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for PathArguments

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ReturnType

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Type

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for bool

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for char

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for f32

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for f64

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for i8

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for i16

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for i32

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for i64

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for i128

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for isize

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for str

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for u8

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for u16

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for u32

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for u64

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for u128

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for usize

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for CString

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for String

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for CStr

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Group

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Ident

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Literal

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Punct

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TokenStream

Source§

impl ToTokens for Attribute

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for MetaList

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for MetaNameValue

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Field

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for FieldsNamed

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for FieldsUnnamed

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Variant

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for VisCrate

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for VisPublic

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for VisRestricted

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for DeriveInput

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ExprArray

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprAssign

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprAssignOp

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprAsync

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprAwait

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprBinary

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ExprBlock

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprBox

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprBreak

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprCall

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ExprCast

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ExprClosure

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprContinue

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprField

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ExprForLoop

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprGroup

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprIf

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprIndex

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ExprLet

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprLit

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ExprLoop

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprMacro

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprMatch

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprMethodCall

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprParen

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ExprPath

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ExprRange

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprReference

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprRepeat

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprReturn

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprStruct

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprTry

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprTryBlock

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprTuple

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprType

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprUnary

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ExprUnsafe

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprWhile

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for ExprYield

Source§

fn to_tokens(&self, _: &mut TokenStream)

Source§

impl ToTokens for Index

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for BoundLifetimes

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ConstParam

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Generics

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for LifetimeDef

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for PredicateEq

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for PredicateLifetime

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for PredicateType

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TraitBound

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypeParam

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for WhereClause

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Lifetime

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for LitBool

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for LitByte

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for LitByteStr

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for LitChar

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for LitFloat

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for LitInt

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for LitStr

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Macro

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for AngleBracketedGenericArguments

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Binding

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Constraint

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ParenthesizedGenericArguments

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Path

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for PathSegment

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Abstract

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Add

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for AddEq

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for And

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for AndAnd

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for AndEq

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for As

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Async

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for At

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Auto

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Await

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Bang

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Become

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Box

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Break

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Caret

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for CaretEq

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Colon2

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Colon

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Comma

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Const

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Continue

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Crate

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Default

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Div

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for DivEq

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Do

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Dollar

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Dot2

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Dot3

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Dot

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for DotDotEq

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Dyn

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Else

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Enum

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Eq

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for EqEq

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Extern

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for FatArrow

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Final

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Fn

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for For

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Ge

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Gt

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for If

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Impl

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for In

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for LArrow

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Le

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Let

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Loop

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Lt

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Macro

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Match

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Mod

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Move

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for MulEq

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Mut

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Ne

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Or

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for OrEq

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for OrOr

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Override

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Pound

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Priv

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Pub

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Question

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for RArrow

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Ref

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Rem

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for RemEq

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Return

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for SelfType

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for SelfValue

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Semi

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Shl

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ShlEq

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Shr

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for ShrEq

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Star

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Static

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Struct

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Sub

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for SubEq

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Super

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Tilde

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Trait

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Try

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Type

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Typeof

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Underscore

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Union

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Unsafe

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Unsized

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Use

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Virtual

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Where

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for While

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Yield

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Abi

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for BareFnArg

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypeArray

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypeBareFn

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypeGroup

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypeImplTrait

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypeInfer

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypeMacro

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypeNever

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypeParen

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypePath

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypePtr

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypeReference

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypeSlice

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypeTraitObject

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for TypeTuple

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl ToTokens for Variadic

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl<'a> ToTokens for ImplGenerics<'a>

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl<'a> ToTokens for Turbofish<'a>

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl<'a> ToTokens for TypeGenerics<'a>

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl<'a, T> ToTokens for Cow<'a, T>
where T: ToOwned + ToTokens + ?Sized,

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl<'a, T> ToTokens for &'a T
where T: ToTokens + ?Sized,

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl<'a, T> ToTokens for &'a mut T
where T: ToTokens + ?Sized,

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl<T> ToTokens for Option<T>
where T: ToTokens,

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl<T> ToTokens for Box<T>
where T: ToTokens + ?Sized,

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl<T> ToTokens for Rc<T>
where T: ToTokens + ?Sized,

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl<T, P> ToTokens for Pair<T, P>
where T: ToTokens, P: ToTokens,

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Source§

impl<T, P> ToTokens for Punctuated<T, P>
where T: ToTokens, P: ToTokens,

Source§

fn to_tokens(&self, tokens: &mut TokenStream)

Implementors§