aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/python/Pygments/py3/pygments/lexers/html.py
diff options
context:
space:
mode:
authorarcadia-devtools <arcadia-devtools@yandex-team.ru>2022-06-09 14:39:19 +0300
committerarcadia-devtools <arcadia-devtools@yandex-team.ru>2022-06-09 14:39:19 +0300
commitc04b663c7bb4b750deeb8f48f620497ec13da8fa (patch)
tree151ebc8bfdd2ad918caf5e6e2d8013e14272ddf8 /contrib/python/Pygments/py3/pygments/lexers/html.py
parent0d55ca22c507d18c2f35718687e0b06d9915397b (diff)
downloadydb-c04b663c7bb4b750deeb8f48f620497ec13da8fa.tar.gz
intermediate changes
ref:2d4f292087954c9344efdabb7b2a67f466263c65
Diffstat (limited to 'contrib/python/Pygments/py3/pygments/lexers/html.py')
-rw-r--r--contrib/python/Pygments/py3/pygments/lexers/html.py13
1 files changed, 7 insertions, 6 deletions
diff --git a/contrib/python/Pygments/py3/pygments/lexers/html.py b/contrib/python/Pygments/py3/pygments/lexers/html.py
index 2e29f453cd8..1c46504895e 100644
--- a/contrib/python/Pygments/py3/pygments/lexers/html.py
+++ b/contrib/python/Pygments/py3/pygments/lexers/html.py
@@ -4,7 +4,7 @@
Lexers for HTML, XML and related markup.
- :copyright: Copyright 2006-2021 by the Pygments team, see AUTHORS.
+ :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS.
:license: BSD, see LICENSE for details.
"""
@@ -32,6 +32,7 @@ class HtmlLexer(RegexLexer):
"""
name = 'HTML'
+ url = 'https://html.spec.whatwg.org/'
aliases = ['html']
filenames = ['*.html', '*.htm', '*.xhtml', '*.xslt']
mimetypes = ['text/html', 'application/xhtml+xml']
@@ -42,7 +43,7 @@ class HtmlLexer(RegexLexer):
('[^<&]+', Text),
(r'&\S*?;', Name.Entity),
(r'\<\!\[CDATA\[.*?\]\]\>', Comment.Preproc),
- (r'<!--(.|\n)*?-->', Comment.Multiline),
+ (r'<!--.*?-->', Comment.Multiline),
(r'<\?.*?\?>', Comment.Preproc),
('<![^>]*>', Comment.Preproc),
(r'(<)(\s*)(script)(\s*)',
@@ -195,7 +196,7 @@ class XmlLexer(RegexLexer):
Generic lexer for XML (eXtensible Markup Language).
"""
- flags = re.MULTILINE | re.DOTALL | re.UNICODE
+ flags = re.MULTILINE | re.DOTALL
name = 'XML'
aliases = ['xml']
@@ -208,8 +209,8 @@ class XmlLexer(RegexLexer):
'root': [
('[^<&]+', Text),
(r'&\S*?;', Name.Entity),
- (r'\<\!\[CDATA\[.*?\]\]\>', Comment.Preproc),
- (r'<!--(.|\n)*?-->', Comment.Multiline),
+ (r'\<\!\[CDATA\[.*?\]\]\>', Comment.Preproc),
+ (r'<!--.*?-->', Comment.Multiline),
(r'<\?.*?\?>', Comment.Preproc),
('<![^>]*>', Comment.Preproc),
(r'<\s*[\w:.-]+', Name.Tag, 'tag'),
@@ -285,7 +286,7 @@ class HamlLexer(ExtendedRegexLexer):
flags = re.IGNORECASE
# Haml can include " |\n" anywhere,
# which is ignored and used to wrap long lines.
- # To accomodate this, use this custom faux dot instead.
+ # To accommodate this, use this custom faux dot instead.
_dot = r'(?: \|\n(?=.* \|)|.)'
# In certain places, a comma at the end of the line