summaryrefslogtreecommitdiff
path: root/Lib/symbol.py
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1996-07-21 02:17:52 +0000
committerGuido van Rossum <guido@python.org>1996-07-21 02:17:52 +0000
commitedc78aa75c22bc58203ad631f942b211ec751726 (patch)
tree20c55b0079d9a4de716c59dd0a4fa55b0a3f5a3d /Lib/symbol.py
parentefae53467292fb136181c902a2f0c389870c09ba (diff)
downloadcpython-edc78aa75c22bc58203ad631f942b211ec751726.tar.gz
Changes for new parser module (Fred Drake)
Diffstat (limited to 'Lib/symbol.py')
-rwxr-xr-xLib/symbol.py69
1 files changed, 37 insertions, 32 deletions
diff --git a/Lib/symbol.py b/Lib/symbol.py
index f3ec122625..36f178a7ee 100755
--- a/Lib/symbol.py
+++ b/Lib/symbol.py
@@ -21,40 +21,45 @@ continue_stmt = 273
return_stmt = 274
raise_stmt = 275
import_stmt = 276
-global_stmt = 277
-access_stmt = 278
-accesstype = 279
-exec_stmt = 280
-compound_stmt = 281
-if_stmt = 282
-while_stmt = 283
-for_stmt = 284
-try_stmt = 285
-except_clause = 286
-suite = 287
-test = 288
-and_test = 289
-not_test = 290
-comparison = 291
-comp_op = 292
-expr = 293
-xor_expr = 294
-and_expr = 295
-shift_expr = 296
-arith_expr = 297
-term = 298
-factor = 299
-atom = 300
-lambdef = 301
-trailer = 302
-subscript = 303
-exprlist = 304
-testlist = 305
-dictmaker = 306
-classdef = 307
+dotted_name = 277
+global_stmt = 278
+access_stmt = 279
+accesstype = 280
+exec_stmt = 281
+compound_stmt = 282
+if_stmt = 283
+while_stmt = 284
+for_stmt = 285
+try_stmt = 286
+except_clause = 287
+suite = 288
+test = 289
+and_test = 290
+not_test = 291
+comparison = 292
+comp_op = 293
+expr = 294
+xor_expr = 295
+and_expr = 296
+shift_expr = 297
+arith_expr = 298
+term = 299
+factor = 300
+power = 301
+atom = 302
+lambdef = 303
+trailer = 304
+subscript = 305
+exprlist = 306
+testlist = 307
+dictmaker = 308
+classdef = 309
+arglist = 310
+argument = 311
names = dir()
sym_name = {}
for name in names:
- number = eval(name)
+ number = eval(name)
+ if type(number) is type(0):
sym_name[number] = name