summaryrefslogtreecommitdiff
path: root/markdown
diff options
context:
space:
mode:
authorWaylan Limberg <waylan.limberg@icloud.com>2019-02-07 11:28:52 -0500
committerGitHub <noreply@github.com>2019-02-07 11:28:52 -0500
commit4504f1097ea87de431da8f4e5d0303f22da2e94e (patch)
tree14f26e6e4f54116c4b403bb7dfa6d519ea853670 /markdown
parent9ec83c4c414f27bc8aa490dbac1fe30b49058ae6 (diff)
downloadpython-markdown-4504f1097ea87de431da8f4e5d0303f22da2e94e.tar.gz
Emphasis pattern treats newlines as whitespace (#785)
All whitespace characters should be treated the same by inline patterns. Previoulsy, emphasis patterns were only accounting for spaces, but not other whitepsace characters such as newlines. Fixes #783.
Diffstat (limited to 'markdown')
-rw-r--r--markdown/inlinepatterns.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/markdown/inlinepatterns.py b/markdown/inlinepatterns.py
index dc502c2..88e8ead 100644
--- a/markdown/inlinepatterns.py
+++ b/markdown/inlinepatterns.py
@@ -144,7 +144,7 @@ REFERENCE_RE = LINK_RE
IMAGE_REFERENCE_RE = IMAGE_LINK_RE
# stand-alone * or _
-NOT_STRONG_RE = r'((^| )(\*|_)( |$))'
+NOT_STRONG_RE = r'((^|\s)(\*|_)(\s|$))'
# <http://www.123.com>
AUTOLINK_RE = r'<((?:[Ff]|[Hh][Tt])[Tt][Pp][Ss]?://[^>]*)>'