pub struct StructLiteral { /* private fields */ }Implementations§
Source§impl StructLiteral
impl StructLiteral
Sourcepub fn identifier(&self) -> Option<Identifier>
pub fn identifier(&self) -> Option<Identifier>
The leading shape-name identifier (e.g. Point in Point#{…}).
pub fn shape_name(&self) -> Option<String>
Sourcepub fn fields(&self) -> impl Iterator<Item = StructFieldInit>
pub fn fields(&self) -> impl Iterator<Item = StructFieldInit>
The field initializers, in source order.
Trait Implementations§
Source§impl AstNode for StructLiteral
impl AstNode for StructLiteral
Source§fn can_cast(kind: SyntaxKind) -> bool
fn can_cast(kind: SyntaxKind) -> bool
Returns
true if a node with the given kind can be cast to Self.Source§fn cast(node: SyntaxNode) -> Option<Self>
fn cast(node: SyntaxNode) -> Option<Self>
Try to cast a generic
SyntaxNode into this typed wrapper.Source§fn syntax(&self) -> &SyntaxNode
fn syntax(&self) -> &SyntaxNode
Access the underlying
SyntaxNode.Source§impl Clone for StructLiteral
impl Clone for StructLiteral
Source§fn clone(&self) -> StructLiteral
fn clone(&self) -> StructLiteral
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for StructLiteral
impl Debug for StructLiteral
Source§impl Display for StructLiteral
impl Display for StructLiteral
impl Eq for StructLiteral
Source§impl Hash for StructLiteral
impl Hash for StructLiteral
Source§impl PartialEq for StructLiteral
impl PartialEq for StructLiteral
impl StructuralPartialEq for StructLiteral
Auto Trait Implementations§
impl !RefUnwindSafe for StructLiteral
impl !Send for StructLiteral
impl !Sync for StructLiteral
impl !UnwindSafe for StructLiteral
impl Freeze for StructLiteral
impl Unpin for StructLiteral
impl UnsafeUnpin for StructLiteral
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more