aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib/lexers/python.tes
blob: 6a46f1b946c0da73b671f549149629663229b4fc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
!* Python lexer *!

@[lexer.test.python]{
  _#!Mpython:M[lexer.checkheader]"S -1 '
  :EN*.pyQ*"S -1 '
  :EN*.pywQ*"S -1 '
  :EN*.pyxQ*"S -1 '
  :EN*.pxdQ*"S -1 '
  :EN*.pxiQ*
}

@[lexer.set.python]{
  ESSETILEXERpython
  0ESSETKEYWORDS
    False None True and as assert break class continue
    def del elif else except finally for from global if import in is lambda
    nonlocal not or pass raise return try while with yield
    cdef cimport cpdef
  2,11ESALLOCATESUBSTYLESU.s
  Q.s+0ESSETIDENTIFIERS
    __main__ _dummy_thread _thread abc aifc argparse
    array ast asynchat asyncio asyncore atexit audioop
    base64 bdb binascii binhex bisect builtins bz2
    calendar cgi cgitb chunk cmath cmd code codecs
    codeop collections colorsys compileall concurrent
    configparser contextlib copy copyreg crypt csv
    ctypes curses datetime dbm decimal difflib dis
    distutils dummy_threading email ensurepip enum
    errno faulthandler fcntl filecmp fileinput fnmatch
    formatter fpectl fractions ftplib functools gc getopt
    getpass gettext glob grp gzip hashlib heapq hmac
    html http http imaplib imghdr importlib inspect io
    ipaddress itertools json keyword linecache locale
    logging lzma macpath mailbox mailcap marshal math
    mimetypes mmap modulefinder msilib msvcrt
    multiprocessing netrc nis nntplib numbers operator
    os os ossaudiodev parser pathlib pdb pickle
    pickletools pipes pkgutil platform plistlib poplib posix
    pprint pty pwd py_compile pyclbr queue quopri
    random re readline reprlib resource rlcompleter runpy
    sched select selectors shelve shlex shutil signal site
    smtpd smtplib sndhdr socket socketserver spwd
    sqlite3 ssl stat statistics string stringprep struct
    subprocess sunau symbol symtable sys sysconfig
    syslog tabnanny tarfile telnetlib tempfile termios
    textwrap threading time timeit tkinter token
    tokenize trace traceback tracemalloc tty turtle
    types unicodedata unittest urllib uu uuid venv warnings
    wave weakref webbrowser winreg winsound wsgiref
    xdrlib xml xmlrpc zipfile zipimport zlib
  Q.s+1ESSETIDENTIFIERS
    __future__ with_statement unicode_literals print_function
  :M[color.comment],1M[color.set]
  :M[color.number],2M[color.set]
  :M[color.string],3M[color.set]
  :M[color.string2],4M[color.set]
  :M[color.keyword],5M[color.set]
  :M[color.string2],6M[color.set]
  :M[color.string],7M[color.set]
  :M[color.operator],10M[color.set]
  !!:M[color.variable],11M[color.set]
  :M[color.comment],12M[color.set]
  :M[color.error],13M[color.set]
  :M[color.string],16M[color.set]
  :M[color.string2],17M[color.set]
  :M[color.string2],18M[color.set]
  :M[color.string],19M[color.set]
  :M[color.variable],Q.s+0M[color.set]
  :M[color.variable],Q.s+1M[color.set]
}