FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[Original HTTPS Page]
cpython/Lib/keyword.py at main · python/cpython · GitHub
python
cpython
Repository navigation
Code
Issues
5k+
(5k+)
Pull requests
2.7k
(2.7k)
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
cpython
/
Lib
/
keyword.py
Copy path
More file actions
More file actions
Latest commit
History
History
History
65 lines (57 loc) · 1.06 KB
Breadcrumbs
cpython
/
Lib
/
keyword.py
Copy path
File metadata and controls
65 lines (57 loc) · 1.06 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
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
"""Keywords (from "Grammar/python.gram")
This file is automatically generated; please don't muck it up!
To update the symbols in this file, 'cd' to the top directory of
the python source tree and run:
PYTHONPATH=Tools/peg_generator python3 -m pegen.keywordgen
\
Grammar/python.gram
\
Grammar/Tokens
\
Lib/keyword.py
Alternatively, you can run 'make regen-keyword'.
"""
__all__
=
[
"iskeyword"
,
"issoftkeyword"
,
"kwlist"
,
"softkwlist"
]
kwlist
=
[
'False'
,
'None'
,
'True'
,
'and'
,
'as'
,
'assert'
,
'async'
,
'await'
,
'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'
]
softkwlist
=
[
'_'
,
'case'
,
'lazy'
,
'match'
,
'type'
]
iskeyword
=
frozenset
(
kwlist
).
__contains__
issoftkeyword
=
frozenset
(
softkwlist
).
__contains__
Back
|
FazBrowse Home
|
New Git URL