Repository navigation
fix(render): prevent delimiter adjacency breakouts - #65
Merged
Merged
Conversation
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.
What changed
Keep rendered Markdown safe when nested inline delimiters or adjacent IR nodes would otherwise combine into syntax the IR did not request. Redundant nested bold, italic, and strikethrough wrappers render once. Text beginning with
(is escaped after a bracketed node so a footnote reference cannot become an inline link that consumes later delimiters.Why
The post-merge full fuzz run found a repeated-bold case that closed its outer span before a block node and exposed code as raw HTML. A follow-up local run found the same output-safety failure when a footnote reference and following text combined into an inline link.
Before / After
**delimiters or[^x]followed by(could consume later Markdown delimiters and expose code content as HTML in a downstream GFM renderer.just pre-pr: passed, including 51 output-safety tests and 119 HTML integration tests.render_irfuzz: 500,715 inputs over 61 seconds with no crash.mainbranch.Risk
(after a bracketed node may be escaped.Checklist