aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWaylan Limberg <waylan@gmail.com>2011-06-16 05:37:46 -0400
committerWaylan Limberg <waylan@gmail.com>2011-06-16 05:48:26 -0400
commit619613e2d65cc339e3950483916ce29ed675b4fc (patch)
tree6f254464b4a19001e3190b39a9696636d243a9e8
parent77d67a4d29a1c4e408a998d40017ef375d7450b8 (diff)
downloadmarkdown-619613e2d65cc339e3950483916ce29ed675b4fc.tar.gz
markdown-619613e2d65cc339e3950483916ce29ed675b4fc.tar.bz2
markdown-619613e2d65cc339e3950483916ce29ed675b4fc.zip
Fixed #22. Horizontal rules now work in a few more crazy edge cases. Who actualy useses these? Anyway, we now match markdown.pl.
-rw-r--r--markdown/blockprocessors.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/markdown/blockprocessors.py b/markdown/blockprocessors.py
index 2695932..7223da4 100644
--- a/markdown/blockprocessors.py
+++ b/markdown/blockprocessors.py
@@ -460,7 +460,7 @@ class SetextHeaderProcessor(BlockProcessor):
class HRProcessor(BlockProcessor):
""" Process Horizontal Rules. """
- RE = r'[ ]{0,3}(?P<ch>[*_-])[ ]?((?P=ch)[ ]?){2,}[ ]*'
+ RE = r'[ ]{0,3}((-+[ ]{0,2}){3,}|(_+[ ]{0,2}){3,}|(\*+[ ]{0,2}){3,})[ ]*'
# Detect hr on any line of a block.
SEARCH_RE = re.compile(r'(^|\n)%s(\n|$)' % RE)
# Match a hr on a single line of text.