blob: 6d925ea0484a4cf106402f59b8452e79ec9b80b6 [file] [log] [blame]
Guido van Rossum47478871996-08-21 14:32:37 +00001#! /usr/bin/env python
2#
3# Non-terminal symbols of Python grammar (from "graminit.h")
4#
5# This file is automatically generated; please don't muck it up!
6#
7# To update the symbols in this file, 'cd' to the top directory of
8# the python source tree after building the interpreter and run:
9#
10# PYTHONPATH=Lib:Modules ./python Lib/symbol.py
11#
12# (this path allows the import of string.py, token.py, and regexmodule.so
13# for a site with no installation in place)
Guido van Rossumb31c7f71993-11-11 10:31:23 +000014
Guido van Rossum47478871996-08-21 14:32:37 +000015#--start constants--
Guido van Rossumb31c7f71993-11-11 10:31:23 +000016single_input = 256
17file_input = 257
18eval_input = 258
Guido van Rossumb6775db1994-08-01 11:34:53 +000019funcdef = 259
20parameters = 260
21varargslist = 261
22fpdef = 262
23fplist = 263
24stmt = 264
25simple_stmt = 265
26small_stmt = 266
27expr_stmt = 267
28print_stmt = 268
29del_stmt = 269
30pass_stmt = 270
31flow_stmt = 271
32break_stmt = 272
33continue_stmt = 273
34return_stmt = 274
35raise_stmt = 275
36import_stmt = 276
Guido van Rossum154a5391996-07-21 02:17:52 +000037dotted_name = 277
38global_stmt = 278
Guido van Rossum47478871996-08-21 14:32:37 +000039exec_stmt = 279
40compound_stmt = 280
41if_stmt = 281
42while_stmt = 282
43for_stmt = 283
44try_stmt = 284
45except_clause = 285
46suite = 286
47test = 287
48and_test = 288
49not_test = 289
50comparison = 290
51comp_op = 291
52expr = 292
53xor_expr = 293
54and_expr = 294
55shift_expr = 295
56arith_expr = 296
57term = 297
58factor = 298
59power = 299
60atom = 300
61lambdef = 301
62trailer = 302
63subscriptlist = 303
64subscript = 304
65sliceop = 305
Guido van Rossum154a5391996-07-21 02:17:52 +000066exprlist = 306
67testlist = 307
68dictmaker = 308
69classdef = 309
70arglist = 310
71argument = 311
Guido van Rossum47478871996-08-21 14:32:37 +000072#--end constants--
Guido van Rossumb31c7f71993-11-11 10:31:23 +000073
74names = dir()
75sym_name = {}
76for name in names:
Guido van Rossum154a5391996-07-21 02:17:52 +000077 number = eval(name)
78 if type(number) is type(0):
Guido van Rossumb31c7f71993-11-11 10:31:23 +000079 sym_name[number] = name
Guido van Rossum47478871996-08-21 14:32:37 +000080
81
82def main():
83 import sys
84 import token
85 if len(sys.argv) == 1:
86 sys.argv = sys.argv + ["Include/graminit.h", "Lib/symbol.py"]
87 token.main()
88
89if __name__ == "__main__":
90 main()
91
92#
93# end of file