eric6/ThirdParty/Pygments/pygments/lexers/sieve.py

changeset 7983
54c5cfbb1e29
parent 7701
25f42e208e08
diff -r 48d210e41c65 -r 54c5cfbb1e29 eric6/ThirdParty/Pygments/pygments/lexers/sieve.py
--- a/eric6/ThirdParty/Pygments/pygments/lexers/sieve.py	Thu Jan 14 18:06:56 2021 +0100
+++ b/eric6/ThirdParty/Pygments/pygments/lexers/sieve.py	Thu Jan 14 18:14:15 2021 +0100
@@ -1,69 +1,69 @@
-# -*- coding: utf-8 -*-
-"""
-    pygments.lexers.sieve
-    ~~~~~~~~~~~~~~~~~~~~~
-
-    Lexer for Sieve file format.
-
-    https://tools.ietf.org/html/rfc5228
-    https://tools.ietf.org/html/rfc5173
-    https://tools.ietf.org/html/rfc5229
-    https://tools.ietf.org/html/rfc5230
-    https://tools.ietf.org/html/rfc5232
-    https://tools.ietf.org/html/rfc5235
-    https://tools.ietf.org/html/rfc5429
-    https://tools.ietf.org/html/rfc8580
-
-    :copyright: Copyright 2006-2020 by the Pygments team, see AUTHORS.
-    :license: BSD, see LICENSE for details.
-"""
-
-from pygments.lexer import RegexLexer, bygroups
-from pygments.token import Comment, Name, Literal, String, Text, Punctuation, Keyword
-
-__all__ = ["SieveLexer"]
-
-
-class SieveLexer(RegexLexer):
-    """
-    Lexer for sieve format.
-    """
-    name = 'Sieve'
-    filenames = ['*.siv', '*.sieve']
-    aliases = ['sieve']
-
-    tokens = {
-        'root': [
-            (r'\s+', Text),
-            (r'[();,{}\[\]]', Punctuation),
-            # import:
-            (r'(?i)require',
-             Keyword.Namespace),
-            # tags:
-            (r'(?i)(:)(addresses|all|contains|content|create|copy|comparator|count|days|detail|domain|fcc|flags|from|handle|importance|is|localpart|length|lowerfirst|lower|matches|message|mime|options|over|percent|quotewildcard|raw|regex|specialuse|subject|text|under|upperfirst|upper|value)',
-             bygroups(Name.Tag, Name.Tag)),
-            # tokens:
-            (r'(?i)(address|addflag|allof|anyof|body|discard|elsif|else|envelope|ereject|exists|false|fileinto|if|hasflag|header|keep|notify_method_capability|notify|not|redirect|reject|removeflag|setflag|size|spamtest|stop|string|true|vacation|virustest)',
-             Name.Builtin),
-            (r'(?i)set',
-             Keyword.Declaration),
-            # number:
-            (r'([0-9.]+)([kmgKMG])?',
-             bygroups(Literal.Number, Literal.Number)),
-            # comment:
-            (r'#.*$',
-             Comment.Single),
-            (r'/\*.*\*/',
-             Comment.Multiline),
-            # string:
-            (r'"[^"]*?"',
-             String),
-            # text block:
-            (r'text:',
-             Name.Tag, 'text'),
-        ],
-        'text': [
-            (r'[^.].*?\n', String),
-            (r'^\.', Punctuation, "#pop"),
-        ]
-    }
+# -*- coding: utf-8 -*-
+"""
+    pygments.lexers.sieve
+    ~~~~~~~~~~~~~~~~~~~~~
+
+    Lexer for Sieve file format.
+
+    https://tools.ietf.org/html/rfc5228
+    https://tools.ietf.org/html/rfc5173
+    https://tools.ietf.org/html/rfc5229
+    https://tools.ietf.org/html/rfc5230
+    https://tools.ietf.org/html/rfc5232
+    https://tools.ietf.org/html/rfc5235
+    https://tools.ietf.org/html/rfc5429
+    https://tools.ietf.org/html/rfc8580
+
+    :copyright: Copyright 2006-2021 by the Pygments team, see AUTHORS.
+    :license: BSD, see LICENSE for details.
+"""
+
+from pygments.lexer import RegexLexer, bygroups
+from pygments.token import Comment, Name, Literal, String, Text, Punctuation, Keyword
+
+__all__ = ["SieveLexer"]
+
+
+class SieveLexer(RegexLexer):
+    """
+    Lexer for sieve format.
+    """
+    name = 'Sieve'
+    filenames = ['*.siv', '*.sieve']
+    aliases = ['sieve']
+
+    tokens = {
+        'root': [
+            (r'\s+', Text),
+            (r'[();,{}\[\]]', Punctuation),
+            # import:
+            (r'(?i)require',
+             Keyword.Namespace),
+            # tags:
+            (r'(?i)(:)(addresses|all|contains|content|create|copy|comparator|count|days|detail|domain|fcc|flags|from|handle|importance|is|localpart|length|lowerfirst|lower|matches|message|mime|options|over|percent|quotewildcard|raw|regex|specialuse|subject|text|under|upperfirst|upper|value)',
+             bygroups(Name.Tag, Name.Tag)),
+            # tokens:
+            (r'(?i)(address|addflag|allof|anyof|body|discard|elsif|else|envelope|ereject|exists|false|fileinto|if|hasflag|header|keep|notify_method_capability|notify|not|redirect|reject|removeflag|setflag|size|spamtest|stop|string|true|vacation|virustest)',
+             Name.Builtin),
+            (r'(?i)set',
+             Keyword.Declaration),
+            # number:
+            (r'([0-9.]+)([kmgKMG])?',
+             bygroups(Literal.Number, Literal.Number)),
+            # comment:
+            (r'#.*$',
+             Comment.Single),
+            (r'/\*.*\*/',
+             Comment.Multiline),
+            # string:
+            (r'"[^"]*?"',
+             String),
+            # text block:
+            (r'text:',
+             Name.Tag, 'text'),
+        ],
+        'text': [
+            (r'[^.].*?\n', String),
+            (r'^\.', Punctuation, "#pop"),
+        ]
+    }

eric ide

mercurial