[−][src]Struct serde_lexpr::parse::Options
Various options to influence parser behavior.
Methods
impl Options[src]
pub fn new() -> Options[src]
Construct an empty set of options.
This will recognize no keywords, and parse nil and t as
regular symbols.
pub fn elisp() -> Options[src]
Construct a set of options suitable for parsing Emacs Lisp.
pub fn with_keyword_syntax(self, syntax: KeywordSyntax) -> Options[src]
Add syntax to the recognized keyword syntaxes.
pub fn with_keyword_syntaxes<I, T>(self, styles: I) -> Options where
I: IntoIterator<Item = T>,
T: Borrow<KeywordSyntax>, [src]
I: IntoIterator<Item = T>,
T: Borrow<KeywordSyntax>,
Set the recognized keyword syntaxes.
pub fn with_nil_symbol(self, treatment: NilSymbol) -> Options[src]
Choose how to parse the nil symbol.
pub fn with_t_symbol(self, treatment: TSymbol) -> Options[src]
Choose how to parse the t symbol.
pub fn with_brackets(self, treatment: Brackets) -> Options[src]
Choose how to handle brackets.
pub fn with_string_syntax(self, syntax: StringSyntax) -> Options[src]
Choose the accepted string syntax.
pub fn with_char_syntax(self, syntax: CharSyntax) -> Options[src]
Choose the accepted character syntax.
pub fn keyword_syntax(self, syntax: KeywordSyntax) -> bool[src]
Check wether a keyword syntax is enabled.
pub fn nil_symbol(self) -> NilSymbol[src]
Query the way the nil symbol is handled.
pub fn t_symbol(self) -> TSymbol[src]
Query the way the t symbol is handled.
pub fn brackets(self) -> Brackets[src]
Query the way brackets are handled.
pub fn string_syntax(self) -> StringSyntax[src]
Query the accepted string syntax.
pub fn char_syntax(self) -> CharSyntax[src]
Query the accepted character syntax.
Trait Implementations
impl Clone for Options[src]
impl Copy for Options[src]
impl Debug for Options[src]
impl Default for Options[src]
fn default() -> Options[src]
Construct a default set of options. This corresponds most closely to the Scheme dialect of S-expressions:
- The identifiers
nilandtare treated as regular symbols. - Only octothorpe keywords are recognized.
- Brackets are treated just like parentheses, i.e. indicating a list.
Auto Trait Implementations
impl RefUnwindSafe for Options
impl Send for Options
impl Sync for Options
impl Unpin for Options
impl UnwindSafe for Options
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,
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.
fn to_owned(&self) -> T[src]
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.
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>,