Skip to content

Commit 9d813cc

Browse files
committed
Use cxxdraft-htmlgen macros to annotate non-C++ code and literal fragments.
1 parent 66e0cbf commit 9d813cc

File tree

3 files changed

+318
-318
lines changed

3 files changed

+318
-318
lines changed

source/exceptions.tex

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,11 +135,11 @@
135135
Any exception thrown while destroying
136136
\tcode{t2}
137137
will result in executing
138-
\tcode{handler 2};
138+
\noncxxtcode{handler 2};
139139
any exception thrown while destroying
140140
\tcode{t1}
141141
will result in executing
142-
\tcode{handler 1}.
142+
\noncxxtcode{handler 1}.
143143
\end{example}
144144

145145
\pnum

source/lex.tex

Lines changed: 58 additions & 58 deletions
Original file line numberDiff line numberDiff line change
@@ -566,15 +566,15 @@
566566
\item
567567
\indextext{literal!string!raw}%
568568
If the next character begins a sequence of characters that could be the prefix
569-
and initial double quote of a raw string literal, such as \tcode{R"}, the next preprocessing
569+
and initial double quote of a raw string literal, such as \literaltcode{R"}, the next preprocessing
570570
token shall be a raw string literal. Between the initial and final
571571
double quote characters of the raw string, any transformations performed in phase
572572
2 (line splicing) are reverted; this reversion
573573
shall apply before any \grammarterm{d-char}, \grammarterm{r-char}, or delimiting
574574
parenthesis is identified. The raw string literal is defined as the shortest sequence
575575
of characters that matches the raw-string pattern
576576
\begin{ncbnf}
577-
\opt{encoding-prefix} \terminal{R} raw-string
577+
\opt{encoding-prefix} \literalterminal{R} raw-string
578578
\end{ncbnf}
579579

580580
\item Otherwise, if the next three characters are \tcode{<::} and the subsequent character
@@ -694,15 +694,15 @@
694694
\begin{bnf}
695695
\nontermdef{pp-number}\br
696696
digit\br
697-
\terminal{.} digit\br
697+
\literalterminal{.} digit\br
698698
pp-number identifier-continue\br
699-
pp-number \terminal{'} digit\br
700-
pp-number \terminal{'} nondigit\br
701-
pp-number \terminal{e} sign\br
702-
pp-number \terminal{E} sign\br
703-
pp-number \terminal{p} sign\br
704-
pp-number \terminal{P} sign\br
705-
pp-number \terminal{.}
699+
pp-number \literalterminal{'} digit\br
700+
pp-number \literalterminal{'} nondigit\br
701+
pp-number \literalterminal{e} sign\br
702+
pp-number \literalterminal{E} sign\br
703+
pp-number \literalterminal{p} sign\br
704+
pp-number \literalterminal{P} sign\br
705+
pp-number \literalterminal{.}
706706
\end{bnf}
707707

708708
\pnum
@@ -1124,19 +1124,19 @@
11241124
\nontermdef{binary-literal}\br
11251125
\terminal{0b} binary-digit\br
11261126
\terminal{0B} binary-digit\br
1127-
binary-literal \opt{\terminal{'}} binary-digit
1127+
binary-literal \opt{\literalterminal{'}} binary-digit
11281128
\end{bnf}
11291129

11301130
\begin{bnf}
11311131
\nontermdef{octal-literal}\br
11321132
\terminal{0}\br
1133-
octal-literal \opt{\terminal{'}} octal-digit
1133+
octal-literal \opt{\literalterminal{'}} octal-digit
11341134
\end{bnf}
11351135

11361136
\begin{bnf}
11371137
\nontermdef{decimal-literal}\br
11381138
nonzero-digit\br
1139-
decimal-literal \opt{\terminal{'}} digit
1139+
decimal-literal \opt{\literalterminal{'}} digit
11401140
\end{bnf}
11411141

11421142
\begin{bnf}
@@ -1167,14 +1167,14 @@
11671167
\begin{bnf}
11681168
\nontermdef{hexadecimal-digit-sequence}\br
11691169
hexadecimal-digit\br
1170-
hexadecimal-digit-sequence \opt{\terminal{'}} hexadecimal-digit
1170+
hexadecimal-digit-sequence \opt{\literalterminal{'}} hexadecimal-digit
11711171
\end{bnf}
11721172

11731173
\begin{bnf}
11741174
\nontermdef{hexadecimal-digit} \textnormal{one of}\br
1175-
\terminal{0 1 2 3 4 5 6 7 8 9}\br
1176-
\terminal{a b c d e f}\br
1177-
\terminal{A B C D E F}
1175+
\literalterminal{0 1 2 3 4 5 6 7 8 9}\br
1176+
\literalterminal{a b c d e f}\br
1177+
\literalterminal{A B C D E F}
11781178
\end{bnf}
11791179

11801180
\begin{bnf}
@@ -1189,17 +1189,17 @@
11891189

11901190
\begin{bnf}
11911191
\nontermdef{unsigned-suffix} \textnormal{one of}\br
1192-
\terminal{u U}
1192+
\literalterminal{u U}
11931193
\end{bnf}
11941194

11951195
\begin{bnf}
11961196
\nontermdef{long-suffix} \textnormal{one of}\br
1197-
\terminal{l L}
1197+
\literalterminal{l L}
11981198
\end{bnf}
11991199

12001200
\begin{bnf}
12011201
\nontermdef{long-long-suffix} \textnormal{one of}\br
1202-
\terminal{ll LL}
1202+
\literalterminal{ll LL}
12031203
\end{bnf}
12041204

12051205
\begin{bnf}
@@ -1238,7 +1238,7 @@
12381238

12391239
\pnum
12401240
The \grammarterm{hexadecimal-digit}s
1241-
\tcode{a} through \tcode{f} and \tcode{A} through \tcode{F}
1241+
\literaltcode{a} through \literaltcode{f} and \literaltcode{A} through \literaltcode{F}
12421242
have decimal values ten through fifteen.
12431243
\begin{example}
12441244
The number twelve can be written \tcode{12}, \tcode{014},
@@ -1282,7 +1282,7 @@
12821282
&
12831283
&
12841284
\tcode{unsigned long long int}\\\hline
1285-
\tcode{u} or \tcode{U} &
1285+
\literaltcode{u} or \literaltcode{U} &
12861286
\tcode{unsigned int} &
12871287
\tcode{unsigned int}\\
12881288
&
@@ -1291,7 +1291,7 @@
12911291
&
12921292
\tcode{unsigned long long int} &
12931293
\tcode{unsigned long long int}\\\hline
1294-
\tcode{l} or \tcode{L} &
1294+
\literaltcode{l} or \literaltcode{L} &
12951295
\tcode{long int} &
12961296
\tcode{long int}\\
12971297
&
@@ -1303,22 +1303,22 @@
13031303
&
13041304
&
13051305
\tcode{unsigned long long int}\\\hline
1306-
Both \tcode{u} or \tcode{U} &
1306+
Both \literaltcode{u} or \literaltcode{U} &
13071307
\tcode{unsigned long int} &
13081308
\tcode{unsigned long int}\\
1309-
and \tcode{l} or \tcode{L} &
1309+
and \literaltcode{l} or \literaltcode{L} &
13101310
\tcode{unsigned long long int} &
13111311
\tcode{unsigned long long int}\\\hline
1312-
\tcode{ll} or \tcode{LL} &
1312+
\literaltcode{ll} or \literaltcode{LL} &
13131313
\tcode{long long int} &
13141314
\tcode{long long int}\\
13151315
&
13161316
&
13171317
\tcode{unsigned long long int}\\\hline
1318-
Both \tcode{u} or \tcode{U} &
1318+
Both \literaltcode{u} or \literaltcode{U} &
13191319
\tcode{unsigned long long int} &
13201320
\tcode{unsigned long long int}\\
1321-
and \tcode{ll} or \tcode{LL} &
1321+
and \literaltcode{ll} or \literaltcode{LL} &
13221322
&
13231323
\\\hline
13241324
\tcode{z} or \tcode{Z} &
@@ -1366,12 +1366,12 @@
13661366
\indextext{literal!character}%
13671367
\begin{bnf}
13681368
\nontermdef{character-literal}\br
1369-
\opt{encoding-prefix} \terminal{'} c-char-sequence \terminal{'}
1369+
\opt{encoding-prefix} \literalterminal{'} c-char-sequence \literalterminal{'}
13701370
\end{bnf}
13711371

13721372
\begin{bnf}
13731373
\nontermdef{encoding-prefix} \textnormal{one of}\br
1374-
\terminal{u8}\quad\terminal{u}\quad\terminal{U}\quad\terminal{L}
1374+
\literalterminal{u8}\quad\literalterminal{u}\quad\literalterminal{U}\quad\literalterminal{L}
13751375
\end{bnf}
13761376

13771377
\begin{bnf}
@@ -1424,16 +1424,16 @@
14241424

14251425
\begin{bnf}
14261426
\nontermdef{octal-escape-sequence}\br
1427-
\terminal{\textbackslash} octal-digit\br
1428-
\terminal{\textbackslash} octal-digit octal-digit\br
1429-
\terminal{\textbackslash} octal-digit octal-digit octal-digit\br
1430-
\terminal{\textbackslash o\{} simple-octal-digit-sequence \terminal{\}}\br
1427+
\literalterminal{\textbackslash} octal-digit\br
1428+
\literalterminal{\textbackslash} octal-digit octal-digit\br
1429+
\literalterminal{\textbackslash} octal-digit octal-digit octal-digit\br
1430+
\literalterminal{\textbackslash o\{} simple-octal-digit-sequence \literalterminal{\}}\br
14311431
\end{bnf}
14321432

14331433
\begin{bnf}
14341434
\nontermdef{hexadecimal-escape-sequence}\br
1435-
\terminal{\textbackslash x} simple-hexadecimal-digit-sequence\br
1436-
\terminal{\textbackslash x\{} simple-hexadecimal-digit-sequence \terminal{\}}
1435+
\literalterminal{\textbackslash x} simple-hexadecimal-digit-sequence\br
1436+
\literalterminal{\textbackslash x\{} simple-hexadecimal-digit-sequence \literalterminal{\}}
14371437
\end{bnf}
14381438

14391439
\begin{bnf}
@@ -1621,42 +1621,42 @@
16211621

16221622
\begin{bnf}
16231623
\nontermdef{fractional-constant}\br
1624-
\opt{digit-sequence} \terminal{.} digit-sequence\br
1625-
digit-sequence \terminal{.}
1624+
\opt{digit-sequence} \literalterminal{.} digit-sequence\br
1625+
digit-sequence \literalterminal{.}
16261626
\end{bnf}
16271627

16281628
\begin{bnf}
16291629
\nontermdef{hexadecimal-fractional-constant}\br
1630-
\opt{hexadecimal-digit-sequence} \terminal{.} hexadecimal-digit-sequence\br
1631-
hexadecimal-digit-sequence \terminal{.}
1630+
\opt{hexadecimal-digit-sequence} \literalterminal{.} hexadecimal-digit-sequence\br
1631+
hexadecimal-digit-sequence \literalterminal{.}
16321632
\end{bnf}
16331633

16341634
\begin{bnf}
16351635
\nontermdef{exponent-part}\br
1636-
\terminal{e} \opt{sign} digit-sequence\br
1637-
\terminal{E} \opt{sign} digit-sequence
1636+
\literalterminal{e} \opt{sign} digit-sequence\br
1637+
\literalterminal{E} \opt{sign} digit-sequence
16381638
\end{bnf}
16391639

16401640
\begin{bnf}
16411641
\nontermdef{binary-exponent-part}\br
1642-
\terminal{p} \opt{sign} digit-sequence\br
1643-
\terminal{P} \opt{sign} digit-sequence
1642+
\literalterminal{p} \opt{sign} digit-sequence\br
1643+
\literalterminal{P} \opt{sign} digit-sequence
16441644
\end{bnf}
16451645

16461646
\begin{bnf}
16471647
\nontermdef{sign} \textnormal{one of}\br
1648-
\terminal{+ -}
1648+
\literalterminal{+ -}
16491649
\end{bnf}
16501650

16511651
\begin{bnf}
16521652
\nontermdef{digit-sequence}\br
16531653
digit\br
1654-
digit-sequence \opt{\terminal{'}} digit
1654+
digit-sequence \opt{\literalterminal{'}} digit
16551655
\end{bnf}
16561656

16571657
\begin{bnf}
16581658
\nontermdef{floating-point-suffix} \textnormal{one of}\br
1659-
\terminal{f l f16 f32 f64 f128 bf16 F L F16 F32 F64 F128 BF16}
1659+
\literalterminal{f l f16 f32 f64 f128 bf16 F L F16 F32 F64 F128 BF16}
16601660
\end{bnf}
16611661

16621662
\pnum
@@ -1684,13 +1684,13 @@
16841684
\topline
16851685
\lhdr{\grammarterm{floating-point-suffix}} & \rhdr{type} \\ \capsep
16861686
none & \keyword{double} \\
1687-
\tcode{f} or \tcode{F} & \keyword {float} \\
1688-
\tcode{l} or \tcode{L} & \keyword{long} \keyword{double} \\
1689-
\tcode{f16} or \tcode{F16} & \tcode{std::float16_t} \\
1690-
\tcode{f32} or \tcode{F32} & \tcode{std::float32_t} \\
1691-
\tcode{f64} or \tcode{F64} & \tcode{std::float64_t} \\
1692-
\tcode{f128} or \tcode{F128} & \tcode{std::float128_t} \\
1693-
\tcode{bf16} or \tcode{BF16} & \tcode{std::bfloat16_t} \\
1687+
\literaltcode{f} or \literaltcode{F} & \keyword {float} \\
1688+
\literaltcode{l} or \literaltcode{L} & \keyword{long} \keyword{double} \\
1689+
\literaltcode{f16} or \literaltcode{F16} & \literaltcode{std::float16_t} \\
1690+
\literaltcode{f32} or \literaltcode{F32} & \literaltcode{std::float32_t} \\
1691+
\literaltcode{f64} or \literaltcode{F64} & \literaltcode{std::float64_t} \\
1692+
\literaltcode{f128} or \literaltcode{F128} & \literaltcode{std::float128_t} \\
1693+
\literaltcode{bf16} or \literaltcode{BF16} & \literaltcode{std::bfloat16_t} \\
16941694
\end{simpletypetable}
16951695

16961696
\pnum
@@ -1741,8 +1741,8 @@
17411741
\indextext{literal!string}%
17421742
\begin{bnf}
17431743
\nontermdef{string-literal}\br
1744-
\opt{encoding-prefix} \terminal{"} \opt{s-char-sequence} \terminal{"}\br
1745-
\opt{encoding-prefix} \terminal{R} raw-string
1744+
\opt{encoding-prefix} \literalterminal{"} \opt{s-char-sequence} \literalterminal{"}\br
1745+
\opt{encoding-prefix} \literalterminal{R} raw-string
17461746
\end{bnf}
17471747

17481748
\begin{bnf}
@@ -1766,7 +1766,7 @@
17661766

17671767
\begin{bnf}
17681768
\nontermdef{raw-string}\br
1769-
\terminal{"} \opt{d-char-sequence} \terminal{(} \opt{r-char-sequence} \terminal{)} \opt{d-char-sequence} \terminal{"}
1769+
\literalterminal{"} \opt{d-char-sequence} \literalterminal{(} \opt{r-char-sequence} \literalterminal{)} \opt{d-char-sequence} \literalterminal{"}
17701770
\end{bnf}
17711771

17721772
\begin{bnf}
@@ -1853,7 +1853,7 @@
18531853

18541854
\pnum
18551855
\indextext{literal!string!raw}%
1856-
A \grammarterm{string-literal} that has an \tcode{R}
1856+
A \grammarterm{string-literal} that has an \literaltcode{R}
18571857
\indextext{prefix!\idxcode{R}}%
18581858
in the prefix is a \defn{raw string literal}. The
18591859
\grammarterm{d-char-sequence} serves as a delimiter. The terminating

0 commit comments

Comments
 (0)