pub struct RecordSetter {
pub field: Spanned<Ident>,
pub value: Spanned<Expr>,
pub trailing_comment: Option<Spanned<Comment>>,
}Expand description
A field setter in a record expression or record update.
name = expr
Fields§
§field: Spanned<Ident>§value: Spanned<Expr>§trailing_comment: Option<Spanned<Comment>>Optional trailing inline comment: field = value -- comment.
elm-format keeps a short comment attached at the end of the setter,
before the next , or }. Preserved only when the comment appears
on the same source line as the value.
Trait Implementations§
Source§impl Clone for RecordSetter
impl Clone for RecordSetter
Source§fn clone(&self) -> RecordSetter
fn clone(&self) -> RecordSetter
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 RecordSetter
impl Debug for RecordSetter
Source§impl PartialEq for RecordSetter
impl PartialEq for RecordSetter
Source§fn eq(&self, other: &RecordSetter) -> bool
fn eq(&self, other: &RecordSetter) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for RecordSetter
impl StructuralPartialEq for RecordSetter
Auto Trait Implementations§
impl Freeze for RecordSetter
impl RefUnwindSafe for RecordSetter
impl Send for RecordSetter
impl Sync for RecordSetter
impl Unpin for RecordSetter
impl UnsafeUnpin for RecordSetter
impl UnwindSafe for RecordSetter
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