aboutsummaryrefslogtreecommitdiffstats
path: root/markdown/inlinepatterns.py
diff options
context:
space:
mode:
Diffstat (limited to 'markdown/inlinepatterns.py')
-rw-r--r--markdown/inlinepatterns.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/markdown/inlinepatterns.py b/markdown/inlinepatterns.py
index 218b416..f9d0610 100644
--- a/markdown/inlinepatterns.py
+++ b/markdown/inlinepatterns.py
@@ -140,7 +140,7 @@ REFERENCE_RE = NOIMG + BRK + r'\s?\[([^\]]*)\]'
SHORT_REF_RE = NOIMG + r'\[([^\]]+)\]'
# ![alt text][2]
-IMAGE_REFERENCE_RE = r'\!' + BRK + '\s?\[([^\]]*)\]'
+IMAGE_REFERENCE_RE = r'\!' + BRK + r'\s?\[([^\]]*)\]'
# stand-alone * or _
NOT_STRONG_RE = r'((^| )(\*|_)( |$))'
@@ -170,7 +170,7 @@ def dequote(string):
return string
-ATTR_RE = re.compile("\{@([^\}]*)=([^\}]*)}") # {@id=123}
+ATTR_RE = re.compile(r"\{@([^\}]*)=([^\}]*)}") # {@id=123}
def handleAttributes(text, parent):
@@ -351,7 +351,7 @@ class HtmlPattern(Pattern):
try:
return self.markdown.serializer(value)
except:
- return '\%s' % value
+ return r'\%s' % value
return util.INLINE_PLACEHOLDER_RE.sub(get_stash, text)