std::encoding::yamlYAML values with automatic cleanup and independent copies.
Inspect values with checked accessors. Mutate a var value with set
or push; supplied children remain usable and independent.
parseParse YAML, retaining the parser's diagnostic on failure.
from_u64Construct an exact unsigned integer, including values above i64's range.
from_floatConstruct a YAML float, including NaN and infinity.
from_stringfrom_boolnullencodeEncode any data value as YAML text. Records encode as objects keyed by field name in declaration order.
decodeDecode YAML text as T. A failure names the path of the value that did
not fit, for example Type: .tags[1]: expected string, found integer.
KindThe represented YAML kind, without exposing runtime tags.
NullBoolIntegerFloatStringSequenceMappingTaggedParseErrorMalformed YAML input.
Invalid(string)EncodeErrorA value cannot be represented as YAML text.
Invalid(string)AccessErrorA checked access or mutation failed without changing the value.
WrongKind(Kind, Kind)Expected kind, followed by the actual kind.
IntegerRangeThe integer does not fit the requested signed or unsigned type.
InvalidIndex(i64)The index is negative or exceeds the supported runtime index range.
UnsupportedMappingKey(Kind)A mapping key is not a string; its kind is preserved in the error.
ValueAn owning YAML value. Assignment and extraction produce independent values. Cleanup is automatic; the representation remains private.
ValueMethodsRead a float without coercing an integer to a float.
Missing keys return None; an explicit null returns Some(value).
Return independent string keys in insertion order, rejecting other key kinds.
Missing elements return None; unsupported indices return InvalidIndex.
Set a string-keyed field, preserving the supplied child.
Append an independent copy of the child.