Croissant Runtime
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
crsn/crsn/crsn-sexp/README.md

19 lines
1.1 KiB

CRSN Sexp
=========
This is an updated and extended version of the "sexp" crate by Clark Gaebel: [https://github.com/cgaebel/sexp](https://github.com/cgaebel/sexp).
## Changes from "cgaebel/sexp"
- Updated to the 2018 Rust edition (that is, removed `try!()` and such)
- All parsed atoms now track their source location. This enables better error reporting in subsequent parsing and processing.
- Quoted strings now support C-style escapes other than `\"`, such as `\n`, `\t` and `\\`.
- Unrecognized escapes result in the slash being removed and the next character being taken literally. Use `\\` to enter a backslash.
- Added special parsing of "character literals" that use single quotes (`'A'`) and may contain backslash escapes (`'\n'`).
- This does not interfere with "apostrophe tokens" like `'foo`, that becomes an unquoted string atom.
- Added "quoted string", "unsigned" and "character" atom types
- Added parsing for `0x123`, `#ff00ff` and `0b123456`
- Numeric literals may now contain underscores to separate digit groups
- Numbers are preferably parsed as the unsigned atom (u64). The signed atom (i64) is only used for negative numbers.
.