-
Notifications
You must be signed in to change notification settings - Fork 96
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sync in changes made to cmark-gfm after 2021-08-01 #29
Conversation
… with oss-fuzz first.
Python 3.8 has removed the cgi.escape function, which had been deprecated since version 3.2. html.escape does the same thing, use that instead. Signed-off-by: Keith Packard <[email protected]>
When two footnote references are adjacent, the handle_close_bracket function will first try to match the closing bracket to a link reference. Now we reset the subject's state, so that the parser correctly picks up both footnote references.
…ark_nodes. Sometimes, the autolinker will go ahead and greedily split input into multiple text nodes in the hopes of matching a hyperlink. This broke footnotes, which expected a singular node. Instead of relying on the tokenizing to have worked perfectly, when handling footnote references we now simply insert the reference based on the closing bracket and ignore and delete any existing and superfluous nodes.
When a footnote is referenced multiple times, we now insert multiple backrefs linking back to each reference. In order to do this, we had to change how footnote ref link labels work away from an incrementing index, and instead use footnote reference label text *plus* an index.
…in multiple places and multiple backrefs.
…ontain 'w' or '_'.
Move CI build over to Actions, per `@jgm`'s upstream work.
… intent more obvious.
…ade sure to free allocated string in commonmark.c
Add data attributes for easier styling within dotcom. Also, add the aria-label for accessibility.
…nkrefs-autolinker Fix footnotes: nested, confused for link refs & mangled by the autolinker
…fnref-label-and-backrefs Fix footnotes plus fix footnote reference labels and backrefs
…otes Add data attributes for footnotes
Bump version to `0.29.0.gfm.2`
* added explicit check for UINT16_MAX boundary on row->n_columns * added additional checks for row_from_string NULL returns to prevent NULL dereferences on error cases * added additional check to ensure n_columns between marker and header rows always match prior to any alignment processing * allocate alignment array based on marker rows rather than header rows * prevent memory leak on dangling node when encountering row_from_string error in try_opening_table_row * add explicit integer overflow error marker to not overload offset semantics in row_from_string with other implied error conditions
0.29.0.gfm.3 patch
4c40013
to
2cd664e
Compare
I've updated this PR to include the changes from GHSA-mc3g-88wq-6f4x (effectively just the version number bump and the commit history, because the patch itself was merged in #36), bringing this up to date with the current |
compiler: | ||
- c: 'clang' | ||
cpp: 'clang++' | ||
- c: 'gcc' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does that make sense on macOS
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If gcc is available on macOS in GitHub Actions (i assume so since this is an upstream change), i guess they want to make sure to test it. However, this doesn't affect our fork, since we don't use GitHub Actions.
2cd664e
to
131078b
Compare
I rebased this PR to include new changes on |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I haven't actually looked into all of this, but this just upstream stuff right?
Yeah, it's all upstream. The only change on top of that is to update the readme to remove the GitHub Actions badge. |
In August and September, GitHub made various updates to cmark-gfm to re-enable footnotes. This PR pulls in the upsream changes to the
gfm
branch so that we can have those fixes in Swift-DocC as well.There were also updates to the testing scripts and an additional configuration for GitHub Actions. The latter doesn't affect this repo since we don't use GitHub Actions.
I've tested these changes by manually loading them into swift-markdown and swift-docc and ensuring that the tests pass. Note that the local test suite doesn't completely pass due to changes we made to support inline attributes. A fix for that will come in a later PR (which will also help #28).