Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Ecosystem comparison

How noyalib lines up against the other Rust YAML libraries it is likely to be evaluated alongside. Cells reflect the state of the named crates as of 2026-05 (verified against the latest crates.io release of each); corrections welcome via PR.

For per-crate migration guides (function tables, behavioural notes, drop-in shim notes), see MIGRATION.md and the per-crate guides linked from there.

noyalibserde_ymlserde_yaml_ngsaphyryaml-rust2rust-yaml
YAML Test Suite100% strict (406/406)—————
Pure RustYesNo (C-FFI)No (C-FFI)YesYesYes
Zero unsafeYesNoNoYesYesYes
Serde integrationYesYesYesYesNoYes
Streaming deserYesNoNoNoNoNo
#![no_std]YesNoNoNoNoNo
Zero-copy scalarsYesNoNoNoNoYes
SIMD scanningYes (memchr + bitmask)NoNoNoNoNo
SWAR numeric parseYesNoNoNoNoNo
Parallel multi-docYes (parallel::parse)NoNoNoNoNo
DoS hardened~12 budgetsBasicBasicYesNoYes
Pluggable policiesYes (policy::Policy)NoNoNoNoNo
Secret interpolationYes (${VAR})NoNoYesNoNo
CST manipulationYes (cst::Document)NoNoNoNoNo
Native LSPYes (noyalib-lsp)NoNoNoNoNo
MCP serverYes (noyalib-mcp)NoNoNoNoNo
JSON Schema codegenYes (schema_for)NoNoNoNoNo
JSON Schema validateYes (validate_against_schema)NoNoNoNoNo
Schema-driven autofixYes (coerce_to_schema)NoNoNoNoNo
miette diagnosticsYesNoNoNoNoNo
WASM338 KBNoNoNoNoNo
Source spansYesNoNoYesNoNo
YAML 1.1 compatYesYesYesNoYesNo
SerializationYesYesYesYesNoNo
Path queriesquery("..name")NoNoNoNoNo
Zero-copy ASTBorrowedValue<'a>NoNoNoNoPartial

Reading the table

  • YAML Test Suite (100% strict) — noyalib is the only Rust YAML implementation that passes all 406 active cases in the YAML 1.2 official Test Suite under strict comparison. The other libraries either don’t track this metric publicly or apply lenience that lets cases the spec rejects pass through.
  • C-FFI rows — serde_yml and serde_yaml_ng (the active forks of dtolnay/serde-yaml) wrap libyaml via unsafe-libyaml in their dep tree. Pure-Rust alternatives don’t have this transitive C dependency.
  • Streaming deser — noyalib::from_str::<T> walks parser events directly into the typed target without building an intermediate Value AST. The other crates that do have serde integration build the AST first.
  • DoS hardening (~12 budgets) — max_depth, max_alias_expansions, max_document_length, max_sequence_length, max_mapping_keys, max_events, max_nodes, max_total_scalar_bytes, max_documents, max_merge_keys, plus the cumulative-alias-byte budget, the alias/anchor ratio guard, and the per-document size cap. See POLICIES.md for defaults and override knobs.

How to verify a row yourself

The cells were sourced from each crate’s Cargo.toml, docs.rs API surface, and recent release notes. To re-verify (e.g. after a new release elsewhere):

# Source-of-truth dump for any crate's exported surface:
cargo doc --no-deps -p <crate> --open

# Dependency tree (catches the libyaml C-FFI hop):
cargo tree -p <crate> --target all

If you spot a stale or wrong cell, file a correction at https://github.com/sebastienrousseau/noyalib/issues.