# HG changeset patch # User Paul Boddie # Date 1532985591 -7200 # Node ID b89502ed29bed2e6f30ffcbb3ef1e449b5b30043 # Parent 429c8546ae9f1099b9152b93dfc7f25d58be89ca Fixed misinterpretation of macros as table attributes. diff -r 429c8546ae9f -r b89502ed29be moinformat/parsers/moin.py --- a/moinformat/parsers/moin.py Mon Jul 30 23:19:20 2018 +0200 +++ b/moinformat/parsers/moin.py Mon Jul 30 23:19:51 2018 +0200 @@ -660,7 +660,9 @@ # Table contents: - "tableattrs" : r"<", # < + "tableattrs" : join(("<", # lt + excl("<"))), # not-lt + "tablecell" : r"\|\|", # || "tableend" : join((group("extra", r"\s*?"), # ws... (optional) diff -r 429c8546ae9f -r b89502ed29be tests/test_tables.tree --- a/tests/test_tables.tree Mon Jul 30 23:19:20 2018 +0200 +++ b/tests/test_tables.tree Mon Jul 30 23:19:51 2018 +0200 @@ -45,4 +45,8 @@ TableRow TableCell Text + TableRow + TableCell + Macro + Text Block diff -r 429c8546ae9f -r b89502ed29be tests/test_tables.txt --- a/tests/test_tables.txt Mon Jul 30 23:19:20 2018 +0200 +++ b/tests/test_tables.txt Mon Jul 30 23:19:51 2018 +0200 @@ -8,3 +8,4 @@ ||<20%%name="value"> Bad separator || ||<20%xx-2> Strange attributes || +||<
> Macro, not attributes ||