[−][src]Struct rune::ast::ExprObject
Parse an object expression.
Examples
use rune::{testing, ast}; testing::roundtrip::<ast::ExprObject>("Foo {\"foo\": 42}"); testing::roundtrip::<ast::ExprObject>("#{\"foo\": 42}"); testing::roundtrip::<ast::ExprObject>("#{\"foo\": 42,}");
Fields
attributes: Vec<Attribute>
Attributes associated with object.
ident: ObjectIdent
An object identifier.
assignments: Braced<FieldAssign, Comma>
Assignments in the object.
Implementations
impl ExprObject
[src]
pub fn parse_with_meta(
parser: &mut Parser<'_>,
attributes: Vec<Attribute>,
ident: ObjectIdent
) -> Result<Self, ParseError>
[src]
parser: &mut Parser<'_>,
attributes: Vec<Attribute>,
ident: ObjectIdent
) -> Result<Self, ParseError>
Parse #ident and attach the given meta
Trait Implementations
impl Clone for ExprObject
[src]
pub fn clone(&self) -> ExprObject
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Debug for ExprObject
[src]
impl Eq for ExprObject
[src]
impl Parse for ExprObject
[src]
pub fn parse(parser: &mut Parser<'_>) -> Result<Self, ParseError>
[src]
impl PartialEq<ExprObject> for ExprObject
[src]
pub fn eq(&self, other: &ExprObject) -> bool
[src]
pub fn ne(&self, other: &ExprObject) -> bool
[src]
impl Peek for ExprObject
[src]
impl Spanned for ExprObject
[src]
impl StructuralEq for ExprObject
[src]
impl StructuralPartialEq for ExprObject
[src]
impl ToTokens for ExprObject
[src]
pub fn to_tokens(&self, context: &MacroContext, stream: &mut TokenStream)
[src]
Auto Trait Implementations
impl RefUnwindSafe for ExprObject
[src]
impl Send for ExprObject
[src]
impl Sync for ExprObject
[src]
impl Unpin for ExprObject
[src]
impl UnwindSafe for ExprObject
[src]
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>,