Skip to content

Commit 858a93d

Browse files
committed
Use \opt{arg} instead of suffix \opt{}
This was machine-converted using sed -i 's/\([-a-z]\{1,\}\)\opt{}/\opt{\1}/g' *.tex sed -i 's/::\opt{}/\opt{::}/g' *.tex sed -i 's/\(\terminal{[^}]*}\)\opt{}/\opt{\1}/g' *.tex
1 parent 605cf5c commit 858a93d

17 files changed

+247
-247
lines changed

source/access.tex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@
200200
(Clause~\ref{class.derived}):
201201

202202
\begin{ncbnftab}
203-
access-specifier \terminal{:} member-specification\opt{}
203+
access-specifier \terminal{:} \opt{member-specification}
204204
\end{ncbnftab}
205205

206206
An

source/basic.tex

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

688688
\begin{ncbnf}
689-
class-key attribute-specifier-seq\opt{} identifier \terminal{;}
689+
class-key \opt{attribute-specifier-seq} identifier \terminal{;}
690690
\end{ncbnf}
691691

692692
the \grammarterm{identifier} is declared to be a
@@ -1657,7 +1657,7 @@
16571657
\grammarterm{qualified-id} of the form:
16581658

16591659
\begin{ncbnf}
1660-
nested-name-specifier\opt{} class-name \terminal{::} \terminal{\tilde} class-name
1660+
\opt{nested-name-specifier} class-name \terminal{::} \terminal{\tilde} class-name
16611661
\end{ncbnf}
16621662

16631663
the second \grammarterm{class-name} is looked up in the same scope as the
@@ -2017,7 +2017,7 @@
20172017
following form:
20182018

20192019
\begin{ncbnf}
2020-
class-key attribute-specifier-seq\opt{} identifier \terminal{;}
2020+
class-key \opt{attribute-specifier-seq} identifier \terminal{;}
20212021
\end{ncbnf}
20222022

20232023
the \grammarterm{identifier} is looked up according
@@ -2032,7 +2032,7 @@
20322032
form:
20332033

20342034
\begin{ncbnf}
2035-
class-key attribute-specifier-seq\opt{} identifier \terminal{;}
2035+
class-key \opt{attribute-specifier-seq} identifier \terminal{;}
20362036
\end{ncbnf}
20372037

20382038
the \grammarterm{elaborated-type-specifier} is a declaration that
@@ -2198,7 +2198,7 @@
21982198

21992199
\begin{bnf}
22002200
\nontermdef{translation-unit}\br
2201-
declaration-seq\opt{}
2201+
\opt{declaration-seq}
22022202
\end{bnf}
22032203

22042204
\pnum

source/classes.tex

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -29,18 +29,18 @@
2929

3030
\begin{bnf}
3131
\nontermdef{class-specifier}\br
32-
class-head \terminal{\{} member-specification\opt{} \terminal{\}}
32+
class-head \terminal{\{} \opt{member-specification} \terminal{\}}
3333
\end{bnf}
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 \opt{attribute-specifier-seq} class-head-name \opt{class-virt-specifier} \opt{base-clause}\br
38+
class-key \opt{attribute-specifier-seq} \opt{base-clause}
3939
\end{bnf}
4040

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

4646
\begin{bnf}
@@ -442,13 +442,13 @@
442442

443443
\begin{bnf}
444444
\nontermdef{member-specification}\br
445-
member-declaration member-specification\opt{}\br
446-
access-specifier \terminal{:} member-specification\opt{}
445+
member-declaration \opt{member-specification}\br
446+
access-specifier \terminal{:} \opt{member-specification}
447447
\end{bnf}
448448

449449
\begin{bnf}
450450
\nontermdef{member-declaration}\br
451-
attribute-specifier-seq\opt{} decl-specifier-seq\opt{} member-declarator-list\opt{} \terminal{;}\br
451+
\opt{attribute-specifier-seq} \opt{decl-specifier-seq} \opt{member-declarator-list} \terminal{;}\br
452452
function-definition\br
453453
using-declaration\br
454454
static_assert-declaration\br
@@ -466,9 +466,9 @@
466466

467467
\begin{bnf}
468468
\nontermdef{member-declarator}\br
469-
declarator virt-specifier-seq\opt{} pure-specifier\opt{}\br
470-
declarator brace-or-equal-initializer\opt{}\br
471-
identifier\opt{} attribute-specifier-seq\opt{} \terminal{:} constant-expression
469+
declarator \opt{virt-specifier-seq} \opt{pure-specifier}\br
470+
declarator \opt{brace-or-equal-initializer}\br
471+
\opt{identifier} \opt{attribute-specifier-seq} \terminal{:} constant-expression
472472
\end{bnf}
473473

474474
\begin{bnf}
@@ -1294,7 +1294,7 @@
12941294
A \grammarterm{member-declarator} of the form
12951295

12961296
\begin{ncbnftab}
1297-
identifier\opt{} attribute-specifier-seq\opt{} \terminal{:} constant-expression
1297+
\opt{identifier} \opt{attribute-specifier-seq} \terminal{:} constant-expression
12981298
\end{ncbnftab}
12991299

13001300
\indextext{\idxcode{:}!bit-field declaration}%

0 commit comments

Comments
 (0)