Context
YAML 1.2.2 core schema treats << as an ordinary mapping key, but many YAML documents use the YAML 1.1 merge-key convention. The module should support merge-key expansion as an explicit compatibility capability, never as default YAML 1.2 behavior.
Official references:
Current State
The module correctly treats << as ordinary mapping data by default. There is no opt-in parameter to expand merge keys when consuming YAML from tools that still emit the YAML 1.1 merge-key convention.
Objective
Add explicit merge-key expansion that composes with parsing, validation, formatting, merging, and PowerShell projection without changing the YAML 1.2 default.
PowerShell Design Considerations
- Use an explicit switch such as
-ResolveMergeKey; do not overload default parsing.
- Keep parameter symmetry across string conversion, file import, validation, formatting, and merging.
- Make merge expansion happen before projection so rich PowerShell objects receive the expanded mapping.
- Keep error behavior classified for invalid merge values, duplicate merge keys, and merge cycles.
Tasks
Benefits
- Improves interoperability with common YAML files that still use merge keys.
- Keeps YAML 1.2 conformance by default.
- Gives script authors a clear and discoverable compatibility switch.
Acceptance Criteria
Related
Context
YAML 1.2.2 core schema treats
<<as an ordinary mapping key, but many YAML documents use the YAML 1.1 merge-key convention. The module should support merge-key expansion as an explicit compatibility capability, never as default YAML 1.2 behavior.Official references:
spec/Merge-Key-Resolution.mdCurrent State
The module correctly treats
<<as ordinary mapping data by default. There is no opt-in parameter to expand merge keys when consuming YAML from tools that still emit the YAML 1.1 merge-key convention.Objective
Add explicit merge-key expansion that composes with parsing, validation, formatting, merging, and PowerShell projection without changing the YAML 1.2 default.
PowerShell Design Considerations
-ResolveMergeKey; do not overload default parsing.Tasks
Benefits
Acceptance Criteria
<<remains ordinary mapping data without the opt-in switch.Test-Yaml,Format-Yaml, andMerge-Yamlhonor the opt-in behavior consistently.Related
spec/Merge-Key-Resolution.md