Give the CommonMark blocks a directive form for what their spelling cannot hold #26

Merged
lilleman merged 5 commits from tick-2f into main 2026-08-27 16:08:32 +02:00
Owner

The eight block nodes CommonMark spells get directive sections in spec/flavour.md, taken wherever
their own spelling holds neither the attributes nor the marks the node carries — localId on any of
them, codeBlock's hideLineNumbers, uniqueId and wrap, and the values CommonMark cannot
render: a heading level absent or outside 1-6, a language no info string holds, an order whose
markers would run past 999999999. hardBreak gains localId and text on the inline directive it
already had.

Four maintainer decisions, recorded under 2f in todo.md: the codeBlock directive's body is one
fenced code block so the language stays on the fence line and renderers still highlight it; a
language the info string cannot hold rides the language attribute instead, which retires 2d's
carry for the reserved adf; order: 1 keeps the plain 1. and a list carrying no order takes
the directive form; and the plain spelling gives way wherever it cannot render what the node
carries, not only where it has no place for it.

ambiguous-attribute-spelling, unspellable-code-block-language, unspellable-list-marker,
unspelled-block-marks and unsupported-heading-level leave ConvertErrorCode — every cause the
directive form now answers. Content and placement refusals stay, so corpus/unspellable/ keeps the
four documents that are deferred maintainer decisions.

Branch floor 95 → 96.

The eight block nodes CommonMark spells get directive sections in `spec/flavour.md`, taken wherever their own spelling holds neither the attributes nor the marks the node carries — `localId` on any of them, `codeBlock`'s `hideLineNumbers`, `uniqueId` and `wrap`, and the values CommonMark cannot render: a heading level absent or outside 1-6, a language no info string holds, an order whose markers would run past 999999999. `hardBreak` gains `localId` and `text` on the inline directive it already had. Four maintainer decisions, recorded under 2f in `todo.md`: the `codeBlock` directive's body is one fenced code block so the language stays on the fence line and renderers still highlight it; a language the info string cannot hold rides the `language` attribute instead, which retires 2d's carry for the reserved `adf`; `order: 1` keeps the plain `1.` and a list carrying no `order` takes the directive form; and the plain spelling gives way wherever it cannot render what the node carries, not only where it has no place for it. `ambiguous-attribute-spelling`, `unspellable-code-block-language`, `unspellable-list-marker`, `unspelled-block-marks` and `unsupported-heading-level` leave `ConvertErrorCode` — every cause the directive form now answers. Content and placement refusals stay, so `corpus/unspellable/` keeps the four documents that are deferred maintainer decisions. Branch floor 95 → 96.
lilleman added 1 commit 2026-08-27 14:13:28 +02:00
lilleman added 1 commit 2026-08-27 15:35:26 +02:00
lilleman added 1 commit 2026-08-27 15:41:41 +02:00
lilleman added 1 commit 2026-08-27 16:02:09 +02:00
lilleman added 1 commit 2026-08-27 16:08:04 +02:00
lilleman merged commit 7ceeaf0e34 into main 2026-08-27 16:08:32 +02:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: larvit/adf-codec#26