[−][src]Enum syntax::ext::expand::AstFragment
A fragment of AST that can be produced by a single macro expansion. Can also serve as an input and intermediate result for macro expansion operations.
Variants
OptExpr(Option<P<Expr>>)
Expr(P<Expr>)
Pat(P<Pat>)
Ty(P<Ty>)
Stmts(SmallVec<[Stmt; 1]>)
Items(SmallVec<[P<Item>; 1]>)
TraitItems(SmallVec<[TraitItem; 1]>)
ImplItems(SmallVec<[ImplItem; 1]>)
ForeignItems(SmallVec<[ForeignItem; 1]>)
Methods
impl AstFragment
[src]
impl AstFragment
pub fn make_opt_expr(self) -> Option<P<Expr>> | [src] |
pub fn make_expr(self) -> P<Expr> | [src] |
pub fn make_pat(self) -> P<Pat> | [src] |
pub fn make_ty(self) -> P<Ty> | [src] |
pub fn make_stmts(self) -> SmallVec<[Stmt; 1]> | [src] |
pub fn make_items(self) -> SmallVec<[P<Item>; 1]> | [src] |
pub fn make_trait_items(self) -> SmallVec<[TraitItem; 1]> | [src] |
pub fn make_impl_items(self) -> SmallVec<[ImplItem; 1]> | [src] |
pub fn make_foreign_items(self) -> SmallVec<[ForeignItem; 1]> | [src] |
pub fn fold_with<F: Folder>(self, folder: &mut F) -> Self | [src] |
pub fn visit_with<'a, V: Visitor<'a>>(&'a self, visitor: &mut V) | [src] |
Auto Trait Implementations
impl !Send for AstFragment
impl !Send for AstFragment
impl !Sync for AstFragment
impl !Sync for AstFragment
Blanket Implementations
impl<T> From for T
[src]
impl<T> From for T
impl<T, U> Into for T where
U: From<T>,
[src]
impl<T, U> Into for T where
U: From<T>,
impl<T, U> TryFrom for T where
T: From<U>,
[src]
impl<T, U> TryFrom for T where
T: From<U>,
type Error = !
🔬 This is a nightly-only experimental API. (
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error> | [src] |
impl<T> Borrow for T where
T: ?Sized,
[src]
impl<T> Borrow for T where
T: ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
impl<T> BorrowMut for T where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T | [src] |
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
🔬 This is a nightly-only experimental API. (
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error> | [src] |
impl<T> Any for T where
T: 'static + ?Sized,
[src]
impl<T> Any for T where
T: 'static + ?Sized,
fn get_type_id(&self) -> TypeId | [src] |
impl<E> SpecializationError for E
[src]
impl<E> SpecializationError for E
impl<T> Erased for T
[src]
impl<T> Erased for T
impl<T> Send for T where
T: ?Sized,
[src]
impl<T> Send for T where
T: ?Sized,
impl<T> Sync for T where
T: ?Sized,
[src]
impl<T> Sync for T where
T: ?Sized,
impl<T> Erased for T
impl<T> Erased for T