Format-Specific Limits
Integer Notation
Section titled “Integer Notation”Integers can be written in decimal, hexadecimal, octal, or binary form, and may contain underscores as separators. See Integers for the syntax.
Not every file format accepts every form: some reject non-decimal bases, others reject underscores. Writing the number as a string works in all formats — Archmage parses quoted numbers as integers.
rank: "1_024"mask: "0xFF_FF"{ "rank": "1_024", "mask": "0xFF_FF"}Archmage follows YAML 1.2, so yes, no, on, and off are strings, not booleans. Every integer form in Integer Notation works without quotes.
Anchors, aliases, and the merge key << work as in standard YAML.
Archmage reports an error for:
- More than one document in a file
- Infinity and NaN, such as
.infand.nan - Tags, such as
!!str
To keep a value such as 012 as a string, quote it instead of tagging it.
Archmage processes only these XML node types:
DocumentElementAttrTextCDATASection
All other node types (comments, processing instructions, directives) are silently ignored.
Within a single element, attribute names and child element names must not overlap. If an Attr and a child Element share the same name, Archmage reports an error.
Arrays
Section titled “Arrays”Child elements with the same name form an array. Since a single element looks the same as a one-element array, Archmage uses the element path—the element names from the root downward—to decide. If any parent element contains two or more children with the same name, every element with that path is treated as an array, even where it appears only once. If no parent element contains two or more children with that name, add __array__="true" to any one element with that path to make it an array:
<hero> <tag __array__="true">tank</tag></hero>{ "tag": ["tank"]}