Skip to content

Commit b3afbb7

Browse files
committed
fix a typo in mcomp-lang grammar
1 parent 48f15a7 commit b3afbb7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mcomp-lang/mcomp-parsing/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ As usual in EBNF notation, the operator `*` means zero or more occurrences, `+`
7676

7777
BasicType ::= "int" | "char" | "void" | "bool"
7878

79-
Stmt ::= "return" Expr? ";" | Expr ";" | Block | "while" "(" Expr ")" Stmt
79+
Stmt ::= "return" Expr? ";" | Expr? ";" | Block | "while" "(" Expr ")" Stmt
8080
| "if" "(" Expr ")" Stmt "else" Stmt | "if" "(" Expr ")" Stmt
8181
| "for" "(" Expr? ";" Expr? ";" Expr? ")" Stmt
8282

0 commit comments

Comments
 (0)