Improve regex to detect chars immediately after inline literals and roles
ezio-melotti opened this issue · 1 comments
ezio-melotti commented
From #27 (comment): some characters (such as punctuation) are allowed immediately after inline literals and roles, whereas others (alphanumerical) aren't.
The following regex could be improved to catch only the problematic characters:
Line 207 in 1c5adaa
Replacing the last .
with \w
seems to cause lot of false positives though.
JulienPalard commented
I think this is now fixed, not because we enhanced the regex, but because all legitimate constructions are hidden from this detector via the paragraph = clean_paragraph(paragraph)
call one line before the regex.
Don't hesitate to re-open if you have an example.