aboutsummaryrefslogtreecommitdiffstats
path: root/c_compiler/src/c_parser.y
diff options
context:
space:
mode:
Diffstat (limited to 'c_compiler/src/c_parser.y')
-rw-r--r--c_compiler/src/c_parser.y1
1 files changed, 1 insertions, 0 deletions
diff --git a/c_compiler/src/c_parser.y b/c_compiler/src/c_parser.y
index c2086fd..e899467 100644
--- a/c_compiler/src/c_parser.y
+++ b/c_compiler/src/c_parser.y
@@ -270,6 +270,7 @@ ExpressionStatement:
;
JumpStatement: T_RETURN Expression T_SC { $$ = new ReturnStatement($2); }
+ | T_RETURN T_SC { $$ = new ReturnStatement(); }
| T_BREAK T_SC { $$ = new BreakStatement(); }
| T_CONTINUE T_SC { $$ = new ContinueStatement(); }
| T_GOTO T_IDENTIFIER { $$ = new GotoStatement(*$2); }