Skip to content

Commit 7fe908f

Browse files
authored
[cpp] Distinguish "preprocessing token" from "token" (#7482)
1 parent 7cbd07c commit 7fe908f

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

source/preprocessor.tex

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@
135135
A \defn{preprocessing directive} consists of a sequence of preprocessing tokens
136136
that satisfies the following constraints:
137137
At the start of translation phase 4,
138-
the first token in the sequence,
138+
the first preprocessing token in the sequence,
139139
referred to as a \defnadj{directive-introducing}{token},
140140
begins with the first character in the source file
141141
(optionally after whitespace containing no new-line characters) or
@@ -170,7 +170,7 @@
170170
one of the two preceding forms.
171171
\end{itemize}
172172

173-
The last token in the sequence is the first token within the sequence that
173+
The last preprocessing token in the sequence is the first preprocessing token within the sequence that
174174
is immediately followed by whitespace containing a new-line character.
175175
\begin{footnote}
176176
Thus,
@@ -446,7 +446,7 @@
446446
\tcode{defined}
447447
unary operator),
448448
just as in normal text.
449-
If the token
449+
If the preprocessing token
450450
\tcode{defined}
451451
is generated as a result of this replacement process
452452
or use of the
@@ -763,7 +763,7 @@
763763
\pnum
764764
A \grammarterm{pp-module} shall not
765765
appear in a context where \tcode{module}
766-
or (if it is the first token of the \grammarterm{pp-module}) \tcode{export}
766+
or (if it is the first preprocessing token of the \grammarterm{pp-module}) \tcode{export}
767767
is an identifier defined as an object-like macro.
768768

769769
\pnum
@@ -824,7 +824,7 @@
824824
\pnum
825825
A \grammarterm{pp-import} shall not
826826
appear in a context where \tcode{import}
827-
or (if it is the first token of the \grammarterm{pp-import}) \tcode{export}
827+
or (if it is the first preprocessing token of the \grammarterm{pp-import}) \tcode{export}
828828
is an identifier defined as an object-like macro.
829829

830830
\pnum
@@ -1209,7 +1209,7 @@
12091209
For each parameter in the replacement list that is neither
12101210
preceded by a \tcode{\#} or \tcode{\#\#} preprocessing token nor
12111211
followed by a \tcode{\#\#} preprocessing token, the preprocessing tokens
1212-
naming the parameter are replaced by a token sequence determined as follows:
1212+
naming the parameter are replaced by a preprocessing token sequence determined as follows:
12131213
\begin{itemize}
12141214
\item
12151215
If the parameter is of the form \grammarterm{va-opt-replacement},
@@ -1415,7 +1415,7 @@
14151415
\end{note}
14161416
If the result is not a valid preprocessing token,
14171417
the behavior is undefined.
1418-
The resulting token is available for further macro replacement.
1418+
The resulting preprocessing token is available for further macro replacement.
14191419
The order of evaluation of
14201420
\tcode{\#\#}
14211421
operators is unspecified.
@@ -1458,7 +1458,7 @@
14581458
"hello, world"
14591459
\end{codeblock}
14601460

1461-
Space around the \tcode{\#} and \tcode{\#\#} tokens in the macro definition
1461+
Space around the \tcode{\#} and \tcode{\#\#} preprocessing tokens in the macro definition
14621462
is optional.
14631463
\end{example}
14641464

@@ -1484,8 +1484,8 @@
14841484
"x ## y"
14851485
\end{codeblock}
14861486

1487-
In other words, expanding \tcode{hash_hash} produces a new token,
1488-
consisting of two adjacent sharp signs, but this new token is not the
1487+
In other words, expanding \tcode{hash_hash} produces a new preprocessing token,
1488+
consisting of two adjacent sharp signs, but this new preprocessing token is not the
14891489
\tcode{\#\#} operator.
14901490
\end{example}
14911491

@@ -1612,7 +1612,7 @@
16121612
i.e., it is one greater than
16131613
the number of new-line characters read or introduced
16141614
in translation phase 1\iref{lex.phases}
1615-
while processing the source file to the current token.
1615+
while processing the source file to the current preprocessing token.
16161616

16171617
\pnum
16181618
A preprocessing directive of the form

0 commit comments

Comments
 (0)