Skip to content
Snippets Groups Projects
Commit 46c475e9 authored by LJ Sonic's avatar LJ Sonic
Browse files

Parse inline table cell separators properly

parent 1e106e12
Branches
Tags
No related merge requests found
...@@ -54,7 +54,9 @@ local grammar = re.compile([=[ ...@@ -54,7 +54,9 @@ local grammar = re.compile([=[
TableCell <- (TableCellSep {| (Attr* Space '|')? |} Blank? {| (TableCellText / NonText)* |}) TableCell <- (TableCellSep {| (Attr* Space '|')? |} Blank? {| (TableCellText / NonText)* |})
-> TableCell -> TableCell
TableCellSep <- Space %nl Blank ('|' !('-' / '}') / '!') TableCellSep <- Space (TableCellNewlineSep / TableCellInlineSep)
TableCellNewlineSep <- %nl Blank ('|' !('-' / '}') / '!')
TableCellInlineSep <- '||' / '!!'
TableCellText <- {| ({ (!(TableCellSep / TableRowSep / TableEnd / NonText / SpecialChar) .)+ } / SpecialChar)+ |} -> Text TableCellText <- {| ({ (!(TableCellSep / TableRowSep / TableEnd / NonText / SpecialChar) .)+ } / SpecialChar)+ |} -> Text
SpecialChar <- '&' [a-zA-Z0-9]+ -> SpecialChar ';' SpecialChar <- '&' [a-zA-Z0-9]+ -> SpecialChar ';'
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment