blob: 678e9efae204f66d15a81bb07dd5b69a83ccb1b1 [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
Guido van Rossuma9a35751997-04-02 05:46:05 +000040assert_stmt = 280
41compound_stmt = 281
42if_stmt = 282
43while_stmt = 283
44for_stmt = 284
45try_stmt = 285
46except_clause = 286
47suite = 287
48test = 288
49and_test = 289
50not_test = 290
51comparison = 291
52comp_op = 292
53expr = 293
54xor_expr = 294
55and_expr = 295
56shift_expr = 296
57arith_expr = 297
58term = 298
59factor = 299
60power = 300
61atom = 301
62lambdef = 302
63trailer = 303
64subscriptlist = 304
65subscript = 305
66sliceop = 306
67exprlist = 307
68testlist = 308
69dictmaker = 309
70classdef = 310
71arglist = 311
72argument = 312
Guido van Rossum47478871996-08-21 14:32:37 +000073#--end constants--
Guido van Rossumb31c7f71993-11-11 10:31:23 +000074
Guido van Rossumb31c7f71993-11-11 10:31:23 +000075sym_name = {}
Fred Drakedc1a0721997-10-06 21:06:29 +000076for _name, _value in globals().items():
77 if type(_value) is type(0):
78 sym_name[_value] = _name
Guido van Rossum47478871996-08-21 14:32:37 +000079
80
81def main():
82 import sys
83 import token
84 if len(sys.argv) == 1:
85 sys.argv = sys.argv + ["Include/graminit.h", "Lib/symbol.py"]
86 token.main()
87
88if __name__ == "__main__":
89 main()
90
91#
92# end of file