fix: add (expr) to dynamic block end (#30)
This commit is contained in:
parent
53a61b6b62
commit
428fd9aeb9
5 changed files with 65346 additions and 54142 deletions
|
|
@ -432,6 +432,19 @@ c
|
|||
contents: (contents
|
||||
(expr)))))
|
||||
|
||||
================================================================================
|
||||
DynamicBlock.3 - End name
|
||||
================================================================================
|
||||
#+BEGIN: a
|
||||
#+END: a
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
(document
|
||||
body: (body
|
||||
(dynamic_block
|
||||
name: (expr)
|
||||
end_name: (expr))))
|
||||
|
||||
================================================================================
|
||||
Comment.1 - Basic
|
||||
================================================================================
|
||||
|
|
|
|||
|
|
@ -234,6 +234,7 @@ org_grammar = {
|
|||
$._nl,
|
||||
optional(field('contents', $.contents)),
|
||||
caseInsensitive('#+end:'),
|
||||
optional(field('end_name', $.expr)),
|
||||
$._eol,
|
||||
),
|
||||
|
||||
|
|
|
|||
|
|
@ -1331,6 +1331,22 @@
|
|||
"named": false,
|
||||
"value": "#+end:"
|
||||
},
|
||||
{
|
||||
"type": "CHOICE",
|
||||
"members": [
|
||||
{
|
||||
"type": "FIELD",
|
||||
"name": "end_name",
|
||||
"content": {
|
||||
"type": "SYMBOL",
|
||||
"name": "expr"
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "BLANK"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "SYMBOL",
|
||||
"name": "_eol"
|
||||
|
|
|
|||
|
|
@ -292,6 +292,16 @@
|
|||
}
|
||||
]
|
||||
},
|
||||
"end_name": {
|
||||
"multiple": false,
|
||||
"required": false,
|
||||
"types": [
|
||||
{
|
||||
"type": "expr",
|
||||
"named": true
|
||||
}
|
||||
]
|
||||
},
|
||||
"name": {
|
||||
"multiple": false,
|
||||
"required": true,
|
||||
|
|
|
|||
119448
src/parser.c
119448
src/parser.c
File diff suppressed because it is too large
Load diff
Loading…
Add table
Reference in a new issue