Struct rune::ast::ExprTuple [−][src]
An expression to construct a literal tuple.
Examples
use rune::{testing, ast}; testing::roundtrip::<ast::ExprTuple>("(1, \"two\")"); testing::roundtrip::<ast::ExprTuple>("(1, 2,)"); testing::roundtrip::<ast::ExprTuple>("(1, 2, foo())");
Fields
attributes: Vec<Attribute>
Attributes associated with tuple.
items: Parenthesized<Expr, Comma>
Items in the tuple.
Implementations
impl ExprTuple
[src]
pub fn parse_with_meta(
parser: &mut Parser<'_>,
attributes: Vec<Attribute>
) -> Result<Self, ParseError>
[src]
parser: &mut Parser<'_>,
attributes: Vec<Attribute>
) -> Result<Self, ParseError>
Parse #ident and attach the given meta
impl ExprTuple
[src]
pub fn parse_from_first_expr(
parser: &mut Parser<'_>,
attributes: Vec<Attribute>,
open: OpenParen,
expr: Expr
) -> Result<Self, ParseError>
[src]
parser: &mut Parser<'_>,
attributes: Vec<Attribute>,
open: OpenParen,
expr: Expr
) -> Result<Self, ParseError>
Start parsing literal tuple from the middle of an expression.
Trait Implementations
impl Clone for ExprTuple
[src]
impl Debug for ExprTuple
[src]
impl Eq for ExprTuple
[src]
impl Parse for ExprTuple
[src]
fn parse(parser: &mut Parser<'_>) -> Result<Self, ParseError>
[src]
impl PartialEq<ExprTuple> for ExprTuple
[src]
impl Spanned for ExprTuple
[src]
impl StructuralEq for ExprTuple
[src]
impl StructuralPartialEq for ExprTuple
[src]
impl ToTokens for ExprTuple
[src]
fn to_tokens(&self, context: &MacroContext, stream: &mut TokenStream)
[src]
Auto Trait Implementations
impl RefUnwindSafe for ExprTuple
impl Send for ExprTuple
impl Sync for ExprTuple
impl Unpin for ExprTuple
impl UnwindSafe for ExprTuple
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,