pub enum SyntaxHint {
Quoted,
Inline,
Inline1,
Inline2,
Block,
Block3,
Block4,
Block5,
Block6,
}Expand description
Hint for serialization: which syntax was used to parse this text.
This hint allows round-tripping to preserve the original syntax when possible.
The generic variants (Inline, Block) let the serializer pick the best syntax
when the exact form doesn’t matter.
Variants§
Quoted
String syntax: "..."
Inline
Generic inline code (serializer picks between Inline1/Inline2)
Inline1
Single backtick inline: `...`
Inline2
Double backtick inline: ``...``
Block
Generic block code (serializer picks backtick count)
Block3
Triple backtick block: ```...```
Block4
Quadruple backtick block: ````...````
Block5
Quintuple backtick block
Block6
Sextuple backtick block
Implementations§
Trait Implementations§
Source§impl Clone for SyntaxHint
impl Clone for SyntaxHint
Source§fn clone(&self) -> SyntaxHint
fn clone(&self) -> SyntaxHint
Returns a duplicate of the value. Read more
1.0.0 · 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 SyntaxHint
impl Debug for SyntaxHint
Source§impl Hash for SyntaxHint
impl Hash for SyntaxHint
Source§impl PartialEq for SyntaxHint
impl PartialEq for SyntaxHint
impl Copy for SyntaxHint
impl Eq for SyntaxHint
impl StructuralPartialEq for SyntaxHint
Auto Trait Implementations§
impl Freeze for SyntaxHint
impl RefUnwindSafe for SyntaxHint
impl Send for SyntaxHint
impl Sync for SyntaxHint
impl Unpin for SyntaxHint
impl UnwindSafe for SyntaxHint
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.