Permalink
Fetching contributors…
Cannot retrieve contributors at this time
53 lines (48 sloc) 721 Bytes
=== Spec Example 2.10. Node for “Sammy Sosa” appears twice in this document
--- from: http://www.yaml.org/spec/1.2/spec.html#id2760658
--- tags: spec alias
--- in-yaml(<)
---
hr:
- Mark McGwire
# Following node labeled SS
- &SS Sammy Sosa
rbi:
- *SS # Subsequent occurrence
- Ken Griffey
--- in-json
{
"hr": [
"Mark McGwire",
"Sammy Sosa"
],
"rbi": [
"Sammy Sosa",
"Ken Griffey"
]
}
--- out-yaml(<)
---
hr:
- Mark McGwire
- &SS Sammy Sosa
rbi:
- *SS
- Ken Griffey
--- test-event
+STR
+DOC ---
+MAP
=VAL :hr
+SEQ
=VAL :Mark McGwire
=VAL &SS :Sammy Sosa
-SEQ
=VAL :rbi
+SEQ
=ALI *SS
=VAL :Ken Griffey
-SEQ
-MAP
-DOC
-STR