Skip to content

Commit 9624614

Browse files
jensmaurertkoeppe
authored andcommitted
Replace \opt with \opt{}
1 parent 4eedcb0 commit 9624614

16 files changed

+194
-194
lines changed

source/access.tex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@
195195
(\ref{class.derived}):
196196

197197
\begin{ncbnftab}
198-
access-specifier \terminal{:} member-specification\opt
198+
access-specifier \terminal{:} member-specification\opt{}
199199
\end{ncbnftab}
200200

201201
An

source/basic.tex

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -776,7 +776,7 @@
776776
\item for a declaration of the form
777777

778778
\begin{ncbnf}
779-
class-key attribute-specifier-seq\opt identifier \terminal{;}
779+
class-key attribute-specifier-seq\opt{} identifier \terminal{;}
780780
\end{ncbnf}
781781

782782
the \grammarterm{identifier} is declared to be a
@@ -1775,7 +1775,7 @@
17751775
\grammarterm{qualified-id} of the form:
17761776

17771777
\begin{ncbnf}
1778-
nested-name-specifier\opt class-name \terminal{::} \terminal{\tilde} class-name
1778+
nested-name-specifier\opt{} class-name \terminal{::} \terminal{\tilde} class-name
17791779
\end{ncbnf}
17801780

17811781
the second \grammarterm{class-name} is looked up in the same scope as the
@@ -2135,7 +2135,7 @@
21352135
following form:
21362136

21372137
\begin{ncbnf}
2138-
class-key attribute-specifier-seq\opt identifier \terminal{;}
2138+
class-key attribute-specifier-seq\opt{} identifier \terminal{;}
21392139
\end{ncbnf}
21402140

21412141
the \grammarterm{identifier} is looked up according
@@ -2150,7 +2150,7 @@
21502150
form:
21512151

21522152
\begin{ncbnf}
2153-
class-key attribute-specifier-seq\opt identifier \terminal{;}
2153+
class-key attribute-specifier-seq\opt{} identifier \terminal{;}
21542154
\end{ncbnf}
21552155

21562156
the \grammarterm{elaborated-type-specifier} is a declaration that
@@ -2316,7 +2316,7 @@
23162316

23172317
\begin{bnf}
23182318
\nontermdef{translation-unit}\br
2319-
declaration-seq\opt
2319+
declaration-seq\opt{}
23202320
\end{bnf}
23212321

23222322
\pnum

source/classes.tex

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,13 @@
3434

3535
\begin{bnf}
3636
\nontermdef{class-head}\br
37-
class-key attribute-specifier-seq\opt class-head-name class-virt-specifier\opt base-clause\opt\br
38-
class-key attribute-specifier-seq\opt base-clause\opt
37+
class-key attribute-specifier-seq\opt{} class-head-name class-virt-specifier\opt{} base-clause\opt{}\br
38+
class-key attribute-specifier-seq\opt{} base-clause\opt{}
3939
\end{bnf}
4040

4141
\begin{bnf}
4242
\nontermdef{class-head-name}\br
43-
nested-name-specifier\opt class-name
43+
nested-name-specifier\opt{} class-name
4444
\end{bnf}
4545

4646
\begin{bnf}
@@ -431,13 +431,13 @@
431431

432432
\begin{bnf}
433433
\nontermdef{member-specification}\br
434-
member-declaration member-specification\opt\br
435-
access-specifier \terminal{:} member-specification\opt
434+
member-declaration member-specification\opt{}\br
435+
access-specifier \terminal{:} member-specification\opt{}
436436
\end{bnf}
437437

438438
\begin{bnf}
439439
\nontermdef{member-declaration}\br
440-
attribute-specifier-seq\opt decl-specifier-seq\opt member-declarator-list\opt{} \terminal{;}\br
440+
attribute-specifier-seq\opt{} decl-specifier-seq\opt{} member-declarator-list\opt{} \terminal{;}\br
441441
function-definition\br
442442
using-declaration\br
443443
static_assert-declaration\br
@@ -455,9 +455,9 @@
455455

456456
\begin{bnf}
457457
\nontermdef{member-declarator}\br
458-
declarator virt-specifier-seq\opt pure-specifier\opt\br
458+
declarator virt-specifier-seq\opt{} pure-specifier\opt{}\br
459459
declarator requires-clause\br
460-
declarator brace-or-equal-initializer\opt\br
460+
declarator brace-or-equal-initializer\opt{}\br
461461
identifier\opt{} attribute-specifier-seq\opt{} \terminal{:} constant-expression brace-or-equal-initializer\opt{}
462462
\end{bnf}
463463

source/declarations.tex

Lines changed: 31 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545

4646
\begin{bnf}
4747
\nontermdef{nodeclspec-function-declaration}\br
48-
attribute-specifier-seq\opt declarator \terminal{;}
48+
attribute-specifier-seq\opt{} declarator \terminal{;}
4949
\end{bnf}
5050

5151
\begin{bnf}
@@ -57,7 +57,7 @@
5757
\nontermdef{simple-declaration}\br
5858
decl-specifier-seq init-declarator-list\opt{} \terminal{;}\br
5959
attribute-specifier-seq decl-specifier-seq init-declarator-list \terminal{;}\br
60-
attribute-specifier-seq\opt decl-specifier-seq ref-qualifier\opt{} \terminal{[} identifier-list \terminal{]} initializer \terminal{;}
60+
attribute-specifier-seq\opt{} decl-specifier-seq ref-qualifier\opt{} \terminal{[} identifier-list \terminal{]} initializer \terminal{;}
6161
\end{bnf}
6262

6363
\begin{bnf}
@@ -93,7 +93,7 @@
9393
\grammarterm{nodeclspec-function-declaration} of the form
9494

9595
\begin{ncsimplebnf}
96-
attribute-specifier-seq\opt decl-specifier-seq\opt init-declarator-list\opt{} \terminal{;}
96+
attribute-specifier-seq\opt{} decl-specifier-seq\opt{} init-declarator-list\opt{} \terminal{;}
9797
\end{ncsimplebnf}
9898

9999
is divided into three parts.
@@ -259,7 +259,7 @@
259259

260260
\begin{bnf}
261261
\nontermdef{decl-specifier-seq}\br
262-
decl-specifier attribute-specifier-seq\opt\br
262+
decl-specifier attribute-specifier-seq\opt{}\br
263263
decl-specifier decl-specifier-seq
264264
\end{bnf}
265265

@@ -1040,7 +1040,7 @@
10401040

10411041
\begin{bnf}
10421042
\nontermdef{type-specifier-seq}\br
1043-
type-specifier attribute-specifier-seq\opt\br
1043+
type-specifier attribute-specifier-seq\opt{}\br
10441044
type-specifier type-specifier-seq
10451045
\end{bnf}
10461046

@@ -1053,7 +1053,7 @@
10531053

10541054
\begin{bnf}
10551055
\nontermdef{defining-type-specifier-seq}\br
1056-
defining-type-specifier attribute-specifier-seq\opt\br
1056+
defining-type-specifier attribute-specifier-seq\opt{}\br
10571057
defining-type-specifier defining-type-specifier-seq
10581058
\end{bnf}
10591059

@@ -1230,9 +1230,9 @@
12301230

12311231
\begin{bnf}
12321232
\nontermdef{simple-type-specifier}\br
1233-
nested-name-specifier\opt type-name\br
1233+
nested-name-specifier\opt{} type-name\br
12341234
nested-name-specifier \terminal{template} simple-template-id\br
1235-
nested-name-specifier\opt template-name\br
1235+
nested-name-specifier\opt{} template-name\br
12361236
\terminal{char}\br
12371237
\terminal{char16_t}\br
12381238
\terminal{char32_t}\br
@@ -1464,10 +1464,10 @@
14641464

14651465
\begin{bnf}
14661466
\nontermdef{elaborated-type-specifier}\br
1467-
class-key attribute-specifier-seq\opt nested-name-specifier\opt identifier\br
1467+
class-key attribute-specifier-seq\opt{} nested-name-specifier\opt{} identifier\br
14681468
class-key simple-template-id\br
1469-
class-key nested-name-specifier \terminal{template}\opt simple-template-id\br
1470-
\terminal{enum} nested-name-specifier\opt identifier
1469+
class-key nested-name-specifier \terminal{template}\opt{} simple-template-id\br
1470+
\terminal{enum} nested-name-specifier\opt{} identifier
14711471
\end{bnf}
14721472

14731473
\pnum
@@ -1482,11 +1482,11 @@
14821482
forms:
14831483

14841484
\begin{ncsimplebnf}
1485-
class-key attribute-specifier-seq\opt identifier \terminal{;}\br
1486-
\terminal{friend} class-key \terminal{::\opt} identifier \terminal{;}\br
1487-
\terminal{friend} class-key \terminal{::\opt} simple-template-id \terminal{;}\br
1485+
class-key attribute-specifier-seq\opt{} identifier \terminal{;}\br
1486+
\terminal{friend} class-key \terminal{::\opt{}} identifier \terminal{;}\br
1487+
\terminal{friend} class-key \terminal{::\opt{}} simple-template-id \terminal{;}\br
14881488
\terminal{friend} class-key nested-name-specifier identifier \terminal{;}\br
1489-
\terminal{friend} class-key nested-name-specifier \terminal{template\opt} simple-template-id \terminal{;}
1489+
\terminal{friend} class-key nested-name-specifier \terminal{template\opt{}} simple-template-id \terminal{;}
14901490
\end{ncsimplebnf}
14911491

14921492
In the first case, the \grammarterm{attribute-specifier-seq}, if any, appertains
@@ -1917,17 +1917,17 @@
19171917

19181918
\begin{bnf}
19191919
\nontermdef{enum-head}\br
1920-
enum-key attribute-specifier-seq\opt enum-head-name\opt enum-base\opt
1920+
enum-key attribute-specifier-seq\opt{} enum-head-name\opt{} enum-base\opt{}
19211921
\end{bnf}
19221922

19231923
\begin{bnf}
19241924
\nontermdef{enum-head-name}\br
1925-
nested-name-specifier\opt identifier
1925+
nested-name-specifier\opt{} identifier
19261926
\end{bnf}
19271927

19281928
\begin{bnf}
19291929
\nontermdef{opaque-enum-declaration}\br
1930-
enum-key attribute-specifier-seq\opt nested-name-specifier\opt identifier enum-base\opt{} \terminal{;}
1930+
enum-key attribute-specifier-seq\opt{} nested-name-specifier\opt{} identifier enum-base\opt{} \terminal{;}
19311931
\end{bnf}
19321932

19331933
\begin{bnf}
@@ -1956,7 +1956,7 @@
19561956

19571957
\begin{bnf}
19581958
\nontermdef{enumerator}\br
1959-
identifier attribute-specifier-seq\opt
1959+
identifier attribute-specifier-seq\opt{}
19601960
\end{bnf}
19611961

19621962
The optional \grammarterm{attribute-specifier-seq} in the \grammarterm{enum-head} and
@@ -2265,12 +2265,12 @@
22652265

22662266
\begin{bnf}
22672267
\nontermdef{named-namespace-definition}\br
2268-
\terminal{inline\opt} \terminal{namespace} attribute-specifier-seq\opt identifier \terminal{\{} namespace-body \terminal{\}}
2268+
\terminal{inline\opt{}} \terminal{namespace} attribute-specifier-seq\opt{} identifier \terminal{\{} namespace-body \terminal{\}}
22692269
\end{bnf}
22702270

22712271
\begin{bnf}
22722272
\nontermdef{unnamed-namespace-definition}\br
2273-
\terminal{inline\opt} \terminal{namespace} attribute-specifier-seq\opt{} \terminal{\{} namespace-body \terminal{\}}
2273+
\terminal{inline\opt{}} \terminal{namespace} attribute-specifier-seq\opt{} \terminal{\{} namespace-body \terminal{\}}
22742274
\end{bnf}
22752275

22762276
\begin{bnf}
@@ -2286,7 +2286,7 @@
22862286

22872287
\begin{bnf}
22882288
\nontermdef{namespace-body}\br
2289-
declaration-seq\opt
2289+
declaration-seq\opt{}
22902290
\end{bnf}
22912291

22922292
\pnum
@@ -2597,7 +2597,7 @@
25972597

25982598
\begin{bnf}
25992599
\nontermdef{qualified-namespace-specifier}\br
2600-
nested-name-specifier\opt namespace-name
2600+
nested-name-specifier\opt{} namespace-name
26012601
\end{bnf}
26022602

26032603
\pnum
@@ -2637,13 +2637,13 @@
26372637

26382638
\begin{bnf}
26392639
\nontermdef{using-declarator-list}\br
2640-
using-declarator \terminal{...}\opt\br
2641-
using-declarator-list \terminal{,} using-declarator \terminal{...}\opt
2640+
using-declarator \terminal{...}\opt{}\br
2641+
using-declarator-list \terminal{,} using-declarator \terminal{...}\opt{}
26422642
\end{bnf}
26432643

26442644
\begin{bnf}
26452645
\nontermdef{using-declarator}\br
2646-
\terminal{typename\opt} nested-name-specifier unqualified-id
2646+
\terminal{typename\opt{}} nested-name-specifier unqualified-id
26472647
\end{bnf}
26482648

26492649
\pnum
@@ -3117,7 +3117,7 @@
31173117

31183118
\begin{bnf}
31193119
\nontermdef{using-directive}\br
3120-
attribute-specifier-seq\opt{} \terminal{using namespace} nested-name-specifier\opt namespace-name \terminal{;}
3120+
attribute-specifier-seq\opt{} \terminal{using namespace} nested-name-specifier\opt{} namespace-name \terminal{;}
31213121
\end{bnf}
31223122

31233123
\pnum
@@ -3592,7 +3592,7 @@
35923592

35933593
\begin{bnf}
35943594
\nontermdef{attribute-specifier-seq}\br
3595-
attribute-specifier-seq\opt attribute-specifier
3595+
attribute-specifier-seq\opt{} attribute-specifier
35963596
\end{bnf}
35973597

35983598
\begin{bnf}
@@ -3614,15 +3614,15 @@
36143614

36153615
\begin{bnf}
36163616
\nontermdef{attribute-list}\br
3617-
attribute\opt\br
3618-
attribute-list \terminal{,} attribute\opt\br
3617+
attribute\opt{}\br
3618+
attribute-list \terminal{,} attribute\opt{}\br
36193619
attribute \terminal{...}\br
36203620
attribute-list \terminal{,} attribute \terminal{...}
36213621
\end{bnf}
36223622

36233623
\begin{bnf}
36243624
\nontermdef{attribute}\br
3625-
attribute-token attribute-argument-clause\opt
3625+
attribute-token attribute-argument-clause\opt{}
36263626
\end{bnf}
36273627

36283628
\begin{bnf}

0 commit comments

Comments
 (0)