Enum syntax::ext::expand::AstFragment [−][src]
pub enum AstFragment { OptExpr(Option<P<Expr>>), Expr(P<Expr>), Pat(P<Pat>), Ty(P<Ty>), Stmts(SmallVector<Stmt>), Items(SmallVector<P<Item>>), TraitItems(SmallVector<TraitItem>), ImplItems(SmallVector<ImplItem>), ForeignItems(SmallVector<ForeignItem>), }
🔬 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 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>>)
🔬 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?
Expr(P<Expr>)
🔬 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?
Pat(P<Pat>)
🔬 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?
Ty(P<Ty>)
🔬 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?
Stmts(SmallVector<Stmt>)
🔬 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?
Items(SmallVector<P<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?
TraitItems(SmallVector<TraitItem>)
🔬 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?
ImplItems(SmallVector<ImplItem>)
🔬 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?
ForeignItems(SmallVector<ForeignItem>)
🔬 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 AstFragment
[src]
impl AstFragment
pub fn make_opt_expr(self) -> Option<P<Expr>>
[src]
pub fn make_opt_expr(self) -> Option<P<Expr>>
🔬 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?
pub fn make_expr(self) -> P<Expr>
[src]
pub fn make_expr(self) -> P<Expr>
🔬 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?
pub fn make_pat(self) -> P<Pat>
[src]
pub fn make_pat(self) -> P<Pat>
🔬 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?
pub fn make_ty(self) -> P<Ty>
[src]
pub fn make_ty(self) -> P<Ty>
🔬 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?
pub fn make_stmts(self) -> SmallVector<Stmt>
[src]
pub fn make_stmts(self) -> SmallVector<Stmt>
🔬 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?
pub fn make_items(self) -> SmallVector<P<Item>>
[src]
pub fn make_items(self) -> SmallVector<P<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?
pub fn make_trait_items(self) -> SmallVector<TraitItem>
[src]
pub fn make_trait_items(self) -> SmallVector<TraitItem>
🔬 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?
pub fn make_impl_items(self) -> SmallVector<ImplItem>
[src]
pub fn make_impl_items(self) -> SmallVector<ImplItem>
🔬 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?
pub fn make_foreign_items(self) -> SmallVector<ForeignItem>
[src]
pub fn make_foreign_items(self) -> SmallVector<ForeignItem>
🔬 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?
pub fn fold_with<F: Folder>(self, folder: &mut F) -> Self
[src]
pub fn fold_with<F: Folder>(self, folder: &mut F) -> Self
🔬 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?
pub fn visit_with<'a, V: Visitor<'a>>(&'a self, visitor: &mut V)
[src]
pub fn visit_with<'a, V: Visitor<'a>>(&'a self, visitor: &mut V)
🔬 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 AstFragment
impl !Send for AstFragment
impl !Sync for AstFragment
impl !Sync for AstFragment