aboutsummaryrefslogtreecommitdiff
path: root/syntax/def.peg
diff options
context:
space:
mode:
Diffstat (limited to 'syntax/def.peg')
-rw-r--r--syntax/def.peg9
1 files changed, 7 insertions, 2 deletions
diff --git a/syntax/def.peg b/syntax/def.peg
index ab809ac..7696a0d 100644
--- a/syntax/def.peg
+++ b/syntax/def.peg
@@ -8,9 +8,9 @@
Markdown <- ('---' NEWLINE MetaBlock* '---' NEWLINE)? Block*
# Block elements
-Block <- Header
+Block <- LinkDefinition
+ / Header
/ List
- / LinkDefinition
/ Paragraph
Header <- '#'+ SPACE* !NEWLINE Words? SPACE* NEWLINE
List <- ([-*]+ / [[:digit:]]+ [).]) (_ (List / Words))? NEWLINE
@@ -49,6 +49,11 @@ NEWLINE <- '\r\n'
# Semantic Markdown
# @see <https://source.jones.dk/semantic-markdown/about/>
+BlockX <- LinkDefinition
+ / PrefixDefinition
+ / Header
+ / List
+ / Paragraph
PrefixDefinition <- '{' CuriePrefix '}' ':' _? SemWord NEWLINE
AnnotatedWordsX <- '[' Words ']'
('{' (SemWords / ![{}] PlainWords) '}')