Expand description
§styx-format
Core formatting and parsing utilities for the Styx configuration language. Handles document parsing, validation, and pretty-printing.
§Sponsors
Thanks to all individual sponsors:
…along with corporate sponsors:
…without whom this work could not exist.
§License
Licensed under either of:
- Apache License, Version 2.0 (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option. Core formatting and parsing utilities for Styx.
This crate provides the low-level building blocks for Styx serialization and deserialization, independent of any specific framework (facet, serde, etc.).
Structs§
- Format
Options - Options for Styx serialization.
- Styx
Writer - Low-level Styx output writer.
Functions§
- can_
be_ bare - Check if a string can be written as a bare scalar.
- count_
escapes - Count escape sequences needed for a quoted string.
- count_
newlines - Count newlines in a string.
- escape_
quoted - Escape a string for quoted output.
- format_
cst - Format a Styx document from its CST.
- format_
object_ braced - Format an Object directly (with braces), not as a root document.
- format_
source - Format a Styx document from source text.
- format_
value - Format a Value as a Styx document string.
- format_
value_ default - Format a Value as a Styx document string with default options.
- unescape_
quoted - Unescape a quoted string.