|
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 |
|
|
1040 | 1040 |
|
1041 | 1041 | \begin{bnf}
|
1042 | 1042 | \nontermdef{type-specifier-seq}\br
|
1043 |
| - type-specifier attribute-specifier-seq\opt\br |
| 1043 | + type-specifier attribute-specifier-seq\opt{}\br |
1044 | 1044 | type-specifier type-specifier-seq
|
1045 | 1045 | \end{bnf}
|
1046 | 1046 |
|
|
1053 | 1053 |
|
1054 | 1054 | \begin{bnf}
|
1055 | 1055 | \nontermdef{defining-type-specifier-seq}\br
|
1056 |
| - defining-type-specifier attribute-specifier-seq\opt\br |
| 1056 | + defining-type-specifier attribute-specifier-seq\opt{}\br |
1057 | 1057 | defining-type-specifier defining-type-specifier-seq
|
1058 | 1058 | \end{bnf}
|
1059 | 1059 |
|
|
1230 | 1230 |
|
1231 | 1231 | \begin{bnf}
|
1232 | 1232 | \nontermdef{simple-type-specifier}\br
|
1233 |
| - nested-name-specifier\opt type-name\br |
| 1233 | + nested-name-specifier\opt{} type-name\br |
1234 | 1234 | 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 |
1236 | 1236 | \terminal{char}\br
|
1237 | 1237 | \terminal{char16_t}\br
|
1238 | 1238 | \terminal{char32_t}\br
|
|
1464 | 1464 |
|
1465 | 1465 | \begin{bnf}
|
1466 | 1466 | \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 |
1468 | 1468 | 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 |
1471 | 1471 | \end{bnf}
|
1472 | 1472 |
|
1473 | 1473 | \pnum
|
|
1482 | 1482 | forms:
|
1483 | 1483 |
|
1484 | 1484 | \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 |
1488 | 1488 | \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{;} |
1490 | 1490 | \end{ncsimplebnf}
|
1491 | 1491 |
|
1492 | 1492 | In the first case, the \grammarterm{attribute-specifier-seq}, if any, appertains
|
|
1917 | 1917 |
|
1918 | 1918 | \begin{bnf}
|
1919 | 1919 | \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{} |
1921 | 1921 | \end{bnf}
|
1922 | 1922 |
|
1923 | 1923 | \begin{bnf}
|
1924 | 1924 | \nontermdef{enum-head-name}\br
|
1925 |
| - nested-name-specifier\opt identifier |
| 1925 | + nested-name-specifier\opt{} identifier |
1926 | 1926 | \end{bnf}
|
1927 | 1927 |
|
1928 | 1928 | \begin{bnf}
|
1929 | 1929 | \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{;} |
1931 | 1931 | \end{bnf}
|
1932 | 1932 |
|
1933 | 1933 | \begin{bnf}
|
|
1956 | 1956 |
|
1957 | 1957 | \begin{bnf}
|
1958 | 1958 | \nontermdef{enumerator}\br
|
1959 |
| - identifier attribute-specifier-seq\opt |
| 1959 | + identifier attribute-specifier-seq\opt{} |
1960 | 1960 | \end{bnf}
|
1961 | 1961 |
|
1962 | 1962 | The optional \grammarterm{attribute-specifier-seq} in the \grammarterm{enum-head} and
|
|
2265 | 2265 |
|
2266 | 2266 | \begin{bnf}
|
2267 | 2267 | \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{\}} |
2269 | 2269 | \end{bnf}
|
2270 | 2270 |
|
2271 | 2271 | \begin{bnf}
|
2272 | 2272 | \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{\}} |
2274 | 2274 | \end{bnf}
|
2275 | 2275 |
|
2276 | 2276 | \begin{bnf}
|
|
2286 | 2286 |
|
2287 | 2287 | \begin{bnf}
|
2288 | 2288 | \nontermdef{namespace-body}\br
|
2289 |
| - declaration-seq\opt |
| 2289 | + declaration-seq\opt{} |
2290 | 2290 | \end{bnf}
|
2291 | 2291 |
|
2292 | 2292 | \pnum
|
|
2597 | 2597 |
|
2598 | 2598 | \begin{bnf}
|
2599 | 2599 | \nontermdef{qualified-namespace-specifier}\br
|
2600 |
| - nested-name-specifier\opt namespace-name |
| 2600 | + nested-name-specifier\opt{} namespace-name |
2601 | 2601 | \end{bnf}
|
2602 | 2602 |
|
2603 | 2603 | \pnum
|
|
2637 | 2637 |
|
2638 | 2638 | \begin{bnf}
|
2639 | 2639 | \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{} |
2642 | 2642 | \end{bnf}
|
2643 | 2643 |
|
2644 | 2644 | \begin{bnf}
|
2645 | 2645 | \nontermdef{using-declarator}\br
|
2646 |
| - \terminal{typename\opt} nested-name-specifier unqualified-id |
| 2646 | + \terminal{typename\opt{}} nested-name-specifier unqualified-id |
2647 | 2647 | \end{bnf}
|
2648 | 2648 |
|
2649 | 2649 | \pnum
|
|
3117 | 3117 |
|
3118 | 3118 | \begin{bnf}
|
3119 | 3119 | \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{;} |
3121 | 3121 | \end{bnf}
|
3122 | 3122 |
|
3123 | 3123 | \pnum
|
|
3592 | 3592 |
|
3593 | 3593 | \begin{bnf}
|
3594 | 3594 | \nontermdef{attribute-specifier-seq}\br
|
3595 |
| - attribute-specifier-seq\opt attribute-specifier |
| 3595 | + attribute-specifier-seq\opt{} attribute-specifier |
3596 | 3596 | \end{bnf}
|
3597 | 3597 |
|
3598 | 3598 | \begin{bnf}
|
|
3614 | 3614 |
|
3615 | 3615 | \begin{bnf}
|
3616 | 3616 | \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 |
3619 | 3619 | attribute \terminal{...}\br
|
3620 | 3620 | attribute-list \terminal{,} attribute \terminal{...}
|
3621 | 3621 | \end{bnf}
|
3622 | 3622 |
|
3623 | 3623 | \begin{bnf}
|
3624 | 3624 | \nontermdef{attribute}\br
|
3625 |
| - attribute-token attribute-argument-clause\opt |
| 3625 | + attribute-token attribute-argument-clause\opt{} |
3626 | 3626 | \end{bnf}
|
3627 | 3627 |
|
3628 | 3628 | \begin{bnf}
|
|
0 commit comments