diff options
author | Polina Dudnik <pdudnik@gmail.com> | 2009-08-17 11:33:32 -0500 |
---|---|---|
committer | Polina Dudnik <pdudnik@gmail.com> | 2009-08-17 11:33:32 -0500 |
commit | c438b2e431066d9324238e1c678ef68a3b721f33 (patch) | |
tree | b79e72b3074441ce01d5c95207f96f71d16bed35 /ext/ply/example/ansic/cparse.py | |
parent | 6654fe02daf6285cb43aa1c6e0e35f6c9c8786f1 (diff) | |
parent | a43ae579dd3128a0ced2238532f26d99db197361 (diff) | |
download | gem5-c438b2e431066d9324238e1c678ef68a3b721f33.tar.xz |
Branch Merge
Diffstat (limited to 'ext/ply/example/ansic/cparse.py')
-rw-r--r-- | ext/ply/example/ansic/cparse.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/ext/ply/example/ansic/cparse.py b/ext/ply/example/ansic/cparse.py index d474378c8..c9b916455 100644 --- a/ext/ply/example/ansic/cparse.py +++ b/ext/ply/example/ansic/cparse.py @@ -155,7 +155,7 @@ def p_struct_declaration_list_1(t): pass def p_struct_declaration_list_2(t): - 'struct_declaration_list : struct_declarator_list struct_declaration' + 'struct_declaration_list : struct_declaration_list struct_declaration' pass # init-declarator-list: @@ -778,12 +778,12 @@ def p_unary_expression_5(t): def p_unary_expression_6(t): 'unary_expression : SIZEOF LPAREN type_name RPAREN' pass - + #unary-operator def p_unary_operator(t): '''unary_operator : AND | TIMES - | PLUS + | PLUS | MINUS | NOT | LNOT ''' @@ -837,7 +837,7 @@ def p_argument_expression_list(t): pass # constant: -def p_constant(t): +def p_constant(t): '''constant : ICONST | FCONST | CCONST''' @@ -849,7 +849,7 @@ def p_empty(t): pass def p_error(t): - print "Whoa. We're hosed" + print("Whoa. We're hosed") import profile # Build the grammar |