|
45 | 45 |
|
46 | 46 | \begin{bnf}
|
47 | 47 | \nontermdef{nodeclspec-function-declaration}\br
|
48 |
| - attribute-specifier-seq\opt declarator \terminal{;} |
| 48 | + attribute-specifier-seq\opt{} declarator \terminal{;} |
49 | 49 | \end{bnf}
|
50 | 50 |
|
51 | 51 | \begin{bnf}
|
|
57 | 57 | \nontermdef{simple-declaration}\br
|
58 | 58 | decl-specifier-seq init-declarator-list\opt{} \terminal{;}\br
|
59 | 59 | 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{;} |
61 | 61 | \end{bnf}
|
62 | 62 |
|
63 | 63 | \begin{bnf}
|
|
93 | 93 | \grammarterm{nodeclspec-function-declaration} of the form
|
94 | 94 |
|
95 | 95 | \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{;} |
97 | 97 | \end{ncsimplebnf}
|
98 | 98 |
|
99 | 99 | is divided into three parts.
|
|
259 | 259 |
|
260 | 260 | \begin{bnf}
|
261 | 261 | \nontermdef{decl-specifier-seq}\br
|
262 |
| - decl-specifier attribute-specifier-seq\opt\br |
| 262 | + decl-specifier attribute-specifier-seq\opt{}\br |
263 | 263 | decl-specifier decl-specifier-seq
|
264 | 264 | \end{bnf}
|
265 | 265 |
|
|
1035 | 1035 |
|
1036 | 1036 | \begin{bnf}
|
1037 | 1037 | \nontermdef{type-specifier-seq}\br
|
1038 |
| - type-specifier attribute-specifier-seq\opt\br |
| 1038 | + type-specifier attribute-specifier-seq\opt{}\br |
1039 | 1039 | type-specifier type-specifier-seq
|
1040 | 1040 | \end{bnf}
|
1041 | 1041 |
|
|
1048 | 1048 |
|
1049 | 1049 | \begin{bnf}
|
1050 | 1050 | \nontermdef{defining-type-specifier-seq}\br
|
1051 |
| - defining-type-specifier attribute-specifier-seq\opt\br |
| 1051 | + defining-type-specifier attribute-specifier-seq\opt{}\br |
1052 | 1052 | defining-type-specifier defining-type-specifier-seq
|
1053 | 1053 | \end{bnf}
|
1054 | 1054 |
|
|
1225 | 1225 |
|
1226 | 1226 | \begin{bnf}
|
1227 | 1227 | \nontermdef{simple-type-specifier}\br
|
1228 |
| - nested-name-specifier\opt type-name\br |
| 1228 | + nested-name-specifier\opt{} type-name\br |
1229 | 1229 | nested-name-specifier \terminal{template} simple-template-id\br
|
1230 |
| - nested-name-specifier\opt template-name\br |
| 1230 | + nested-name-specifier\opt{} template-name\br |
1231 | 1231 | \terminal{char}\br
|
1232 | 1232 | \terminal{char16_t}\br
|
1233 | 1233 | \terminal{char32_t}\br
|
|
1459 | 1459 |
|
1460 | 1460 | \begin{bnf}
|
1461 | 1461 | \nontermdef{elaborated-type-specifier}\br
|
1462 |
| - class-key attribute-specifier-seq\opt nested-name-specifier\opt identifier\br |
| 1462 | + class-key attribute-specifier-seq\opt{} nested-name-specifier\opt{} identifier\br |
1463 | 1463 | class-key simple-template-id\br
|
1464 |
| - class-key nested-name-specifier \terminal{template}\opt simple-template-id\br |
1465 |
| - \terminal{enum} nested-name-specifier\opt identifier |
| 1464 | + class-key nested-name-specifier \terminal{template}\opt{} simple-template-id\br |
| 1465 | + \terminal{enum} nested-name-specifier\opt{} identifier |
1466 | 1466 | \end{bnf}
|
1467 | 1467 |
|
1468 | 1468 | \pnum
|
|
1477 | 1477 | forms:
|
1478 | 1478 |
|
1479 | 1479 | \begin{ncsimplebnf}
|
1480 |
| -class-key attribute-specifier-seq\opt identifier \terminal{;}\br |
1481 |
| -\terminal{friend} class-key \terminal{::\opt} identifier \terminal{;}\br |
1482 |
| -\terminal{friend} class-key \terminal{::\opt} simple-template-id \terminal{;}\br |
| 1480 | +class-key attribute-specifier-seq\opt{} identifier \terminal{;}\br |
| 1481 | +\terminal{friend} class-key \terminal{::\opt{}} identifier \terminal{;}\br |
| 1482 | +\terminal{friend} class-key \terminal{::\opt{}} simple-template-id \terminal{;}\br |
1483 | 1483 | \terminal{friend} class-key nested-name-specifier identifier \terminal{;}\br
|
1484 |
| -\terminal{friend} class-key nested-name-specifier \terminal{template\opt} simple-template-id \terminal{;} |
| 1484 | +\terminal{friend} class-key nested-name-specifier \terminal{template\opt{}} simple-template-id \terminal{;} |
1485 | 1485 | \end{ncsimplebnf}
|
1486 | 1486 |
|
1487 | 1487 | In the first case, the \grammarterm{attribute-specifier-seq}, if any, appertains
|
|
1912 | 1912 |
|
1913 | 1913 | \begin{bnf}
|
1914 | 1914 | \nontermdef{enum-head}\br
|
1915 |
| - enum-key attribute-specifier-seq\opt enum-head-name\opt enum-base\opt |
| 1915 | + enum-key attribute-specifier-seq\opt{} enum-head-name\opt{} enum-base\opt{} |
1916 | 1916 | \end{bnf}
|
1917 | 1917 |
|
1918 | 1918 | \begin{bnf}
|
1919 | 1919 | \nontermdef{enum-head-name}\br
|
1920 |
| - nested-name-specifier\opt identifier |
| 1920 | + nested-name-specifier\opt{} identifier |
1921 | 1921 | \end{bnf}
|
1922 | 1922 |
|
1923 | 1923 | \begin{bnf}
|
1924 | 1924 | \nontermdef{opaque-enum-declaration}\br
|
1925 |
| - enum-key attribute-specifier-seq\opt nested-name-specifier\opt identifier enum-base\opt{} \terminal{;} |
| 1925 | + enum-key attribute-specifier-seq\opt{} nested-name-specifier\opt{} identifier enum-base\opt{} \terminal{;} |
1926 | 1926 | \end{bnf}
|
1927 | 1927 |
|
1928 | 1928 | \begin{bnf}
|
|
1951 | 1951 |
|
1952 | 1952 | \begin{bnf}
|
1953 | 1953 | \nontermdef{enumerator}\br
|
1954 |
| - identifier attribute-specifier-seq\opt |
| 1954 | + identifier attribute-specifier-seq\opt{} |
1955 | 1955 | \end{bnf}
|
1956 | 1956 |
|
1957 | 1957 | The optional \grammarterm{attribute-specifier-seq} in the \grammarterm{enum-head} and
|
|
2260 | 2260 |
|
2261 | 2261 | \begin{bnf}
|
2262 | 2262 | \nontermdef{named-namespace-definition}\br
|
2263 |
| - \terminal{inline\opt} \terminal{namespace} attribute-specifier-seq\opt identifier \terminal{\{} namespace-body \terminal{\}} |
| 2263 | + \terminal{inline\opt{}} \terminal{namespace} attribute-specifier-seq\opt{} identifier \terminal{\{} namespace-body \terminal{\}} |
2264 | 2264 | \end{bnf}
|
2265 | 2265 |
|
2266 | 2266 | \begin{bnf}
|
2267 | 2267 | \nontermdef{unnamed-namespace-definition}\br
|
2268 |
| - \terminal{inline\opt} \terminal{namespace} attribute-specifier-seq\opt{} \terminal{\{} namespace-body \terminal{\}} |
| 2268 | + \terminal{inline\opt{}} \terminal{namespace} attribute-specifier-seq\opt{} \terminal{\{} namespace-body \terminal{\}} |
2269 | 2269 | \end{bnf}
|
2270 | 2270 |
|
2271 | 2271 | \begin{bnf}
|
|
2281 | 2281 |
|
2282 | 2282 | \begin{bnf}
|
2283 | 2283 | \nontermdef{namespace-body}\br
|
2284 |
| - declaration-seq\opt |
| 2284 | + declaration-seq\opt{} |
2285 | 2285 | \end{bnf}
|
2286 | 2286 |
|
2287 | 2287 | \pnum
|
|
2592 | 2592 |
|
2593 | 2593 | \begin{bnf}
|
2594 | 2594 | \nontermdef{qualified-namespace-specifier}\br
|
2595 |
| - nested-name-specifier\opt namespace-name |
| 2595 | + nested-name-specifier\opt{} namespace-name |
2596 | 2596 | \end{bnf}
|
2597 | 2597 |
|
2598 | 2598 | \pnum
|
|
2632 | 2632 |
|
2633 | 2633 | \begin{bnf}
|
2634 | 2634 | \nontermdef{using-declarator-list}\br
|
2635 |
| - using-declarator \terminal{...}\opt\br |
2636 |
| - using-declarator-list \terminal{,} using-declarator \terminal{...}\opt |
| 2635 | + using-declarator \terminal{...}\opt{}\br |
| 2636 | + using-declarator-list \terminal{,} using-declarator \terminal{...}\opt{} |
2637 | 2637 | \end{bnf}
|
2638 | 2638 |
|
2639 | 2639 | \begin{bnf}
|
2640 | 2640 | \nontermdef{using-declarator}\br
|
2641 |
| - \terminal{typename\opt} nested-name-specifier unqualified-id |
| 2641 | + \terminal{typename\opt{}} nested-name-specifier unqualified-id |
2642 | 2642 | \end{bnf}
|
2643 | 2643 |
|
2644 | 2644 | \pnum
|
|
3112 | 3112 |
|
3113 | 3113 | \begin{bnf}
|
3114 | 3114 | \nontermdef{using-directive}\br
|
3115 |
| - attribute-specifier-seq\opt{} \terminal{using namespace} nested-name-specifier\opt namespace-name \terminal{;} |
| 3115 | + attribute-specifier-seq\opt{} \terminal{using namespace} nested-name-specifier\opt{} namespace-name \terminal{;} |
3116 | 3116 | \end{bnf}
|
3117 | 3117 |
|
3118 | 3118 | \pnum
|
|
3587 | 3587 |
|
3588 | 3588 | \begin{bnf}
|
3589 | 3589 | \nontermdef{attribute-specifier-seq}\br
|
3590 |
| - attribute-specifier-seq\opt attribute-specifier |
| 3590 | + attribute-specifier-seq\opt{} attribute-specifier |
3591 | 3591 | \end{bnf}
|
3592 | 3592 |
|
3593 | 3593 | \begin{bnf}
|
|
3609 | 3609 |
|
3610 | 3610 | \begin{bnf}
|
3611 | 3611 | \nontermdef{attribute-list}\br
|
3612 |
| - attribute\opt\br |
3613 |
| - attribute-list \terminal{,} attribute\opt\br |
| 3612 | + attribute\opt{}\br |
| 3613 | + attribute-list \terminal{,} attribute\opt{}\br |
3614 | 3614 | attribute \terminal{...}\br
|
3615 | 3615 | attribute-list \terminal{,} attribute \terminal{...}
|
3616 | 3616 | \end{bnf}
|
3617 | 3617 |
|
3618 | 3618 | \begin{bnf}
|
3619 | 3619 | \nontermdef{attribute}\br
|
3620 |
| - attribute-token attribute-argument-clause\opt |
| 3620 | + attribute-token attribute-argument-clause\opt{} |
3621 | 3621 | \end{bnf}
|
3622 | 3622 |
|
3623 | 3623 | \begin{bnf}
|
|
0 commit comments