Module lexpr::parse

source ·
Expand description

S-expression parser and options.

Terminology

The process of converting S-expressions from their textual representation to values is referred to “reading” in Lisp. To avoid confusion with Rust’s Write trait, lexpr uses “parsing” instead.

Re-exports

  • pub use crate::datum::Datum;
  • pub use crate::datum::Span;

Modules

  • When parsing S-expressions goes wrong.

Structs

  • Iterator over the datums produced by a parser.
  • This type represents the possible errors when parsing S-expression data.
  • S-expression input source that reads from a std::io input stream.
  • Various options to influence parser behavior.
  • Parser for the S-expression text representation.
  • A location in the parsed text.
  • S-expression input source that reads from a slice of bytes.
  • S-expression input source that reads from a UTF-8 string.
  • Iterator over the values produced by a parser.

Enums

Traits

  • Trait used by the parser for iterating over input.

Functions

  • Parse a value from an IO stream of S-expressions, using the default parser options.
  • Parse a value from an IO stream containing a single S-expression.
  • Parse a value from an IO stream of S-expressions, using the parser options suitable for parsing Emacs Lisp.
  • Parse a value from bytes representing a single S-expressions, using the default parser options.
  • Parse a value from bytes representing a single S-expression.
  • Parse a value from bytes representing a single S-expressions, using parser options suitable for Emacs Lisp.
  • Parse a value from a string slice representing a single S-expressions, using the default parser options.
  • Parse a value from a string slice representing a single S-expression.
  • Parse a value from a string slice representing a single S-expression, using parser options suitable for Emacs Lisp.

Type Definitions

  • Alias for a Result with the error type lexpr::Error.