pub struct MapLiteral {
pub entries: HashMap<String, Expr>,
pub key_spans: HashMap<String, Span>,
pub span: Span,
}Expand description
A map literal: {key: expr, …}.
Fields§
§entries: HashMap<String, Expr>§key_spans: HashMap<String, Span>Exact source span for each parsed key token. Synthetic and legacy deserialized maps may omit entries here.
span: SpanTrait Implementations§
Source§impl Clone for MapLiteral
impl Clone for MapLiteral
Source§fn clone(&self) -> MapLiteral
fn clone(&self) -> MapLiteral
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 MapLiteral
impl Debug for MapLiteral
Source§impl<'de> Deserialize<'de> for MapLiteral
impl<'de> Deserialize<'de> for MapLiteral
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for MapLiteral
impl PartialEq for MapLiteral
Source§impl Serialize for MapLiteral
impl Serialize for MapLiteral
impl StructuralPartialEq for MapLiteral
Auto Trait Implementations§
impl Freeze for MapLiteral
impl RefUnwindSafe for MapLiteral
impl Send for MapLiteral
impl Sync for MapLiteral
impl Unpin for MapLiteral
impl UnsafeUnpin for MapLiteral
impl UnwindSafe for MapLiteral
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