Skip to content

Commit eb86ccd

Browse files
committed
[enumerated.types, bitmask.types] Add missing \tcode in a few places, use maths subscripts for indexed placeholders.
1 parent f4ff8ca commit eb86ccd

File tree

1 file changed

+21
-21
lines changed

1 file changed

+21
-21
lines changed

source/lib-intro.tex

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -605,20 +605,21 @@
605605
values~(\ref{basic.fundamental}).}
606606

607607
\pnum
608-
The enumerated type \term{enumerated} can be written:
608+
The enumerated type \tcode{\placeholder{enumerated}} can be written:
609609

610610
\begin{codeblock}
611-
enum @\term{enumerated}@ { @\term{V0}@, @\term{V1}@, @\term{V2}@, @\term{V3}@, ..... };
611+
enum @\placeholder{enumerated}@ { @$\tcode{\placeholder{V}}_{0}$@, @$\tcode{\placeholder{V}}_{1}$@, @$\tcode{\placeholder{V}}_{2}$@, @$\tcode{\placeholder{V}}_{3}$@, ..... };
612612

613-
inline const @\term{enumerated C0}@ (@\term{V0}@);
614-
inline const @\term{enumerated C1}@ (@\term{V1}@);
615-
inline const @\term{enumerated C2}@ (@\term{V2}@);
616-
inline const @\term{enumerated C3}@ (@\term{V3}@);
613+
inline const @$\tcode{\placeholder{enumerated C}}_{0}$@(@$\tcode{\placeholder{V}}_{0}$@);
614+
inline const @$\tcode{\placeholder{enumerated C}}_{1}$@(@$\tcode{\placeholder{V}}_{1}$@);
615+
inline const @$\tcode{\placeholder{enumerated C}}_{2}$@(@$\tcode{\placeholder{V}}_{2}$@);
616+
inline const @$\tcode{\placeholder{enumerated C}}_{3}$@(@$\tcode{\placeholder{V}}_{3}$@);
617617
.....
618618
\end{codeblock}
619619

620620
\pnum
621-
Here, the names \term{C0}, \term{C1}, etc. represent
621+
Here, the names $\tcode{\placeholder{C}}_0$,
622+
$\tcode{\placeholder{C}}_1$, etc.\ represent
622623
\term{enumerated elements}
623624
for this particular enumerated type.
624625
\indextext{type!enumerated}%
@@ -642,16 +643,15 @@
642643

643644
\begin{codeblock}
644645
// For exposition only.
645-
// \tcode{int_type} is an integral type capable of
646-
// representing all values of the bitmask type.
647-
enum @\term{bitmask}@ : int_type {
648-
@\term{V0}@ = 1 << 0, @\term{V1}@ = 1 << 1, @\term{V2}@ = 1 << 2, @\term{V3}@ = 1 << 3, .....
646+
// \tcode{int_type} is an integral type capable of representing all values of the bitmask type.
647+
enum @\placeholder{bitmask}@ : int_type {
648+
@$\tcode{\placeholder{V}}_{0}$@ = 1 << 0, @$\tcode{\placeholder{V}}_{1}$@ = 1 << 1, @$\tcode{\placeholder{V}}_{2}$@ = 1 << 2, @$\tcode{\placeholder{V}}_{3}$@ = 1 << 3, .....
649649
};
650650

651-
inline constexpr @\term{bitmask C0}@(@\term{V0}{}@);
652-
inline constexpr @\term{bitmask C1}@(@\term{V1}{}@);
653-
inline constexpr @\term{bitmask C2}@(@\term{V2}{}@);
654-
inline constexpr @\term{bitmask C3}@(@\term{V3}{}@);
651+
inline constexpr @$\tcode{\placeholder{bitmask C}}_{0}$@(@$\tcode{\placeholder{V}}_{0}{}$@);
652+
inline constexpr @$\tcode{\placeholder{bitmask C}}_{1}$@(@$\tcode{\placeholder{V}}_{1}{}$@);
653+
inline constexpr @$\tcode{\placeholder{bitmask C}}_{2}$@(@$\tcode{\placeholder{V}}_{2}{}$@);
654+
inline constexpr @$\tcode{\placeholder{bitmask C}}_{3}$@(@$\tcode{\placeholder{V}}_{3}{}$@);
655655
.....
656656

657657
constexpr @\term{bitmask}{}@ operator&(@\term{bitmask}{}@ X, @\term{bitmask}{}@ Y) {
@@ -681,21 +681,21 @@
681681
\end{codeblock}
682682

683683
\pnum
684-
Here, the names \term{C0}, \term{C1}, etc. represent
684+
Here, the names $\tcode{\placeholder{C}}_0$,
685+
$\tcode{\placeholder{C}}_1$, etc.\ represent
685686
\term{bitmask elements}
686687
for this particular bitmask type.
687688
\indextext{type!bitmask}%
688-
All such elements have distinct, nonzero values such that, for any pair \term{Ci}
689-
and \term{Cj} where \term{i} != \term{j}, \term{Ci} \& \term{Ci} is nonzero and
690-
\term{Ci} \& \term{Cj} is zero.
689+
All such elements have distinct, nonzero values such that, for any pair $\tcode{\placeholder{C}}_i$
690+
and $\tcode{\placeholder{C}}_j$ where $i \neq j$, \tcode{$\placeholder{C}_i$ \& $\placeholder{C}_i$} is nonzero and
691+
\tcode{$\placeholder{C}_i$ \& $\placeholder{C}_j$} is zero.
691692
\indextext{bitmask!empty}%
692-
Additionally, the value 0 is used to represent an \term{empty bitmask}, in which no
693+
Additionally, the value \tcode{0} is used to represent an \term{empty bitmask}, in which no
693694
bitmask elements are set.
694695

695696
\pnum
696697
The following terms apply to objects and values of
697698
bitmask types:
698-
699699
\begin{itemize}
700700
\item
701701
To

0 commit comments

Comments
 (0)