Library

fkYAML v0.5.0

Versionv0.5.0
Stars★ 153
Released2026-09-17

A C++ header-only YAML library

Release notes

# What's Changed

In this release, YAML parsing compliance has been significantly improved. As a result, fkYAML now passes all test cases in the [YAML Test Suite](https://github.com/yaml/yaml-test-suite), with only a few exceptions. Additionally, depending on the YAML input and the execution environment, parsing performance has improved by a factor of 1.3 or more.  
We have also resolved an issue where anchor resolution would break after serialization, resulting in a more stable round-trip.  
While this release introduces compatibility-breaking changes to the API and ABI, the migration process has been simplified as much as possible.  
For details, please refer to the "Breaking Changes" section down below.  

## :boom: Breaking Changes

This release changes selected parsing results, public API contracts, and the `basic_node` ABI.  
Review the following migration notes before upgrading.

- Support empty keys in block and flow mappings #558 (@sndth)
    - **Breaking changes:** An unquoted empty mapping key is represented by a null node instead of a string node.
    - **Affected users:** Applications that access a deserialized empty mapping key with `node[""]`.
    - **Migration:** Use `node[nullptr]` for an unquoted empty key. An explicitly quoted key (`""`) remains a string key and must continue to use `node[""]`.
- Allocate node properties and document metainfo only when needed #581 (@sndth)
    - **Breaking changes:** The `basic_node` size and layout have changed, and `set_yaml_version_type()` is no longer `noexcept` because it may allocate document metainfo on first use.
    - **Affected users:** Applications and libraries that pass `fkyaml::basic_node` across binary boundaries, depend on its object layout, or require `set_yaml_version_type()` to be `noexcept`.
    - **Migration:** Rebuild all dependent binaries and libraries. Update function types, wrappers, and conditional `noexcept` expressions that require `set_yaml_version_type()` to be non-throwing.
- Let ordered\_map entries be moved when the storage grows #593 (@sndth)
    - **Breaking changes:** `ordered_map::value_type` is now `std::pair<Key, Value>` rather than `std::pair<const Key, Value>`.
    - **Affected users:** Users of `basic_node<std::vector, fkyaml::ordered_map>` whose code explicitly names `ordered_map::value_type` as `std::pair<const Key, Value>`.
    - **Migration:** Replace `std::pair<const Key, Value>` with `std::pair<Key, Value>`, or prefer `auto&` when iterating. Do not modify mapping keys in place.
- Count a document only if it has contents or a directives end marker #595 (@sndth)
    - **Breaking changes:** `deserialize_docs()` no longer returns a document for comment-only, whitespace-only, or bare `...` stream sections.
    - **Affected users:** Callers of `deserialize_docs()` that expect empty nodes for comment-only, whitespace-only, or bare `...` stream sections.
    - **Migration:** Update document-count assumptions and tests. These sections no longer produce a document; an explicit `---` still begins a document.
- Remove deprecated types and functions #645 (@fktn-k)
    - **Breaking changes:** Deprecated node-type, YAML-version, type-query, and value-reference APIs have been removed.
    - **Affected users:** Code using the deprecated `basic_node::node_t`, `basic_node::yaml_version_t`, `type()`, YAML-version accessors, or `get_value_ref<T>()` APIs.
    - **Migration:** Replace them with `node_type`, `yaml_version_type`, `get_type()`, `get_yaml_version_type()`, `set_yaml_version_type()`, and the matching `as_*()` accessor. See the [Migration Guide](../migration.md) for the complete replacement table.

## :zap: Improvements

Internal node attribute management has been refactored, and character classification is now safer for non-ASCII input values.

- Avoid passing a negative char to cctype functions #579 (@sndth)
- Refactor node attribute management #641 (@fktn-k)

## :bug: Bug Fixes

Parsing, seriali…

Share this resource


Discovered 2026-09-18 Source GitHub Archive 2026-09 →