lexpr: S-expressions for Rust ![Latest Version] ![Rustc Version 1.32+]

toml [dependencies] lexpr = "0.1.3"

You may be looking for:

S-expressions are the human-readable, textual representation of code and data in the Lisp family of languages. lexpr aims to provide the tools to:

To get a better idea of the direction lexpr is headed, you may want to take at the TODO or the "why" document.

Supported Lisp dialects

Currently, lexpr focuses on Scheme, mostly based on R6RS and R7RS syntax, with some extensions, and Emacs Lisp. The following features, common across dialects, are not yet implemented:

Further dialect-specific omissions, both ones that are planned to be fixed in the future, and deliberate ones, are listed below.

Scheme

Emacs Lisp

Strings in Emacs Lisp are somewhat difficult to deal with, for the following reasons:

The way lexpr deals with this complexity is the following:

It is expected that these restrictions will not be an impediment when using S-expressions as a data exchange format between Emacs Lisp and Rust programs. In short, S-expressions produced by Rust should be always be parsable by Emacs, and the other direction should work as long as there are no strings with non-unicode "characters" are involved.

Licensing

The code and documentation in the lexpr crate is free software, dual-licensed under the MIT or Apache-2.0 license, at your choosing.

The lexpr repository contains code and documentation adapted from the following projects: