A line with \s\t should not trigger a PREFORMATTED block. The easiest way to handle this is to just
ignore the contents of whole lines when they're just whitespace.
The regex split that splits the lines on "(\n+)"
means that no 'line' contents has newlines characters, so we need to take a look at any tokenizing regex that has \n in it; those newlines don't do anything.
The newlines are tokenized because re.split, when given a capture group, will alternate between the splittéd and splitter texts: ["text", "\n", "text", "\n\n"].
Issue #336
A line with
\s\t
should not trigger a PREFORMATTED block. The easiest way to handle this is to just ignore the contents of whole lines when they're just whitespace.The regex split that splits the lines on "(\n+)" means that no 'line' contents has newlines characters, so we need to take a look at any tokenizing regex that has
\n
in it; those newlines don't do anything.The newlines are tokenized because re.split, when given a capture group, will alternate between the splittéd and splitter texts: ["text", "\n", "text", "\n\n"].