Skip to content

Commit df88130

Browse files
authored
[stmt.pre, re.grammar, gram] Use a separate bnf environment for each nonterminal. (#4070)
1 parent 39e8f2a commit df88130

File tree

3 files changed

+16
-0
lines changed

3 files changed

+16
-0
lines changed

source/grammar.tex

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,9 @@
3333
namespace-name:\br
3434
identifier\br
3535
namespace-alias
36+
\end{ncbnf}
3637

38+
\begin{ncbnf}
3739
namespace-alias:\br
3840
identifier
3941
\end{ncbnf}

source/regex.tex

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3644,7 +3644,9 @@
36443644
ClassAtomExClass\br
36453645
ClassAtomCollatingElement\br
36463646
ClassAtomEquivalence
3647+
\end{ncrebnf}
36473648

3649+
\begin{ncrebnf}
36483650
\renontermdef{IdentityEscape}\br
36493651
SourceCharacter \textnormal{\textbf{but not}} \terminal{c}
36503652
\end{ncrebnf}
@@ -3655,17 +3657,25 @@
36553657
\begin{ncrebnf}
36563658
\renontermdef{ClassAtomExClass}\br
36573659
\terminal{[:} ClassName \terminal{:]}
3660+
\end{ncrebnf}
36583661

3662+
\begin{ncrebnf}
36593663
\renontermdef{ClassAtomCollatingElement}\br
36603664
\terminal{[.} ClassName \terminal{.]}
3665+
\end{ncrebnf}
36613666

3667+
\begin{ncrebnf}
36623668
\renontermdef{ClassAtomEquivalence}\br
36633669
\terminal{[=} ClassName \terminal{=]}
3670+
\end{ncrebnf}
36643671

3672+
\begin{ncrebnf}
36653673
\renontermdef{ClassName}\br
36663674
ClassNameCharacter\br
36673675
ClassNameCharacter ClassName
3676+
\end{ncrebnf}
36683677

3678+
\begin{ncrebnf}
36693679
\renontermdef{ClassNameCharacter}\br
36703680
SourceCharacter \textnormal{\textbf{but not one of}} \terminal{.} \textnormal{\textbf{or}} \terminal{=} \textnormal{\textbf{or}} \terminal{:}
36713681
\end{ncrebnf}

source/statements.tex

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,15 @@
2121
\opt{attribute-specifier-seq} jump-statement\br
2222
declaration-statement\br
2323
\opt{attribute-specifier-seq} try-block
24+
\end{bnf}
2425

26+
\begin{bnf}
2527
\nontermdef{init-statement}\br
2628
expression-statement\br
2729
simple-declaration
30+
\end{bnf}
2831

32+
\begin{bnf}
2933
\nontermdef{condition}\br
3034
expression\br
3135
\opt{attribute-specifier-seq} decl-specifier-seq declarator brace-or-equal-initializer

0 commit comments

Comments
 (0)