A block this parser has never seen must cost it nothing - #18
Merged
Conversation
The row pattern accepted `<sub>` blocks and bare text and nothing else. A future block with any other tag - a `<span>`, a `<code>` - would have made every row unmatchable, and that failure does not read as a parse error over here: it reads as "there are no samples for that". Twice now a NEW KIND of block has arrived from the sample repositories (the `@docs` links, then the `@summary` sentence), and the second one is what this change follows. A block is now `<br>` plus anything, tagged or not, and its TAG decides what it is: no tag is the sentence, `<sub>` is the small type (keywords, then the docs links), and anything else is carried through and ignored. The same generalisation went into abap2UI5/docs' link-samples parser, which reads the same rows and failed the same way this morning. The shape is maintained in three repositories and read in two - it is a contract between five programs, and the two readers must be the forgiving end of it. 41 tests, including a row carrying a <span> block between the two the parser reads
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The row pattern accepted
<sub>blocks and bare text and nothing else. A future block with any other tag — a<span>, a<code>— would have made every row unmatchable, and that failure does not read as a parse error over here: it reads as "there are no samples for that".Twice now a new kind of block has arrived from the sample repositories (the
@docslinks, then the@summarysentence), and the second one is what this change follows.A block is now
<br>plus anything, tagged or not, and its tag decides what it is:<sub>The same generalisation went into
abap2UI5/docs'link-samplesparser, which reads the same rows and failed the same way this morning. The shape is maintained in three repositories and read in two — a contract between five programs, and the two readers must be the forgiving end of it.41 tests, including a row carrying a
<span>block between the two the parser reads.Generated by Claude Code