@willbooster/tree-sitter-markdown 1.0.0 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
CHANGED
|
@@ -19,6 +19,9 @@ digits of an ordered list marker with `'0'` and `'9'` instead of calling `isdigi
|
|
|
19
19
|
own ABI number (`0x57420001`) and load only with that fork's runtime, version 2.0.0 or later: upstream's tree-sitter
|
|
20
20
|
runtime rejects them. They parse as the parsers in upstream's 0.5.3 packages do, with these exceptions:
|
|
21
21
|
|
|
22
|
+
- A closing code fence at the end of a file is recognized even without a trailing line ending.
|
|
23
|
+
- Trailing spaces and tabs at EOF are excluded from the preceding block’s inline range, as they are before a line ending.
|
|
24
|
+
- Ordered lists interrupt a paragraph only when their first marker is `1.` or `1)`.
|
|
22
25
|
- A NUL character is part of the text around it, in both grammars, where upstream's lexers report it as an unexpected
|
|
23
26
|
character in an `ERROR` node.
|
|
24
27
|
- A block that starts with bracketed text holding a backslash escape or a character reference, such as
|
package/package.json
CHANGED
|
@@ -169,7 +169,7 @@ module.exports = grammar({
|
|
|
169
169
|
optional($.info_string),
|
|
170
170
|
$._newline,
|
|
171
171
|
optional($.code_fence_content),
|
|
172
|
-
optional(seq(alias($._fenced_code_block_end_backtick, $.fenced_code_block_delimiter), $._close_block, $._newline)),
|
|
172
|
+
optional(seq(alias($._fenced_code_block_end_backtick, $.fenced_code_block_delimiter), $._close_block, choice($._newline, $._eof))),
|
|
173
173
|
$._block_close,
|
|
174
174
|
),
|
|
175
175
|
seq(
|
|
@@ -178,11 +178,11 @@ module.exports = grammar({
|
|
|
178
178
|
optional($.info_string),
|
|
179
179
|
$._newline,
|
|
180
180
|
optional($.code_fence_content),
|
|
181
|
-
optional(seq(alias($._fenced_code_block_end_tilde, $.fenced_code_block_delimiter), $._close_block, $._newline)),
|
|
181
|
+
optional(seq(alias($._fenced_code_block_end_tilde, $.fenced_code_block_delimiter), $._close_block, choice($._newline, $._eof))),
|
|
182
182
|
$._block_close,
|
|
183
183
|
),
|
|
184
184
|
)),
|
|
185
|
-
code_fence_content: $ => repeat1(choice($._newline, $.
|
|
185
|
+
code_fence_content: $ => repeat1(choice($._newline, $._code_fence_line)),
|
|
186
186
|
info_string: $ => choice(
|
|
187
187
|
seq($.language, repeat(choice($._line, $.backslash_escape, $.entity_reference, $.numeric_character_reference))),
|
|
188
188
|
seq(
|
|
@@ -580,6 +580,7 @@ module.exports = grammar({
|
|
|
580
580
|
|
|
581
581
|
$._pipe_table_start,
|
|
582
582
|
$._pipe_table_line_ending,
|
|
583
|
+
$._code_fence_line,
|
|
583
584
|
],
|
|
584
585
|
precedences: $ => [
|
|
585
586
|
[$._setext_heading1, $._block],
|
|
Binary file
|
|
Binary file
|