File tree Expand file tree Collapse file tree 4 files changed +117
-127
lines changed Expand file tree Collapse file tree 4 files changed +117
-127
lines changed Original file line number Diff line number Diff line change 815
815
816
816
\rSec 2[basic.scope.pdecl]{Point of declaration}
817
817
818
+ \indextext {declaration!point of|(}%
819
+
818
820
\pnum
819
- \indextext {name!point of declaration}%
820
- The \defn {point of declaration} for a name is immediately after its
821
+ \indextext {name!point of declaration|see{declaration, point of}}%
822
+ \indextext {point of!declaration|see{declaration, point of}}%
823
+ The \defnx {point of declaration}{declaration!point of} for a name is immediately after its
821
824
complete declarator\iref {dcl.decl } and before its
822
825
\grammarterm {initializer} (if any), except as noted below. \begin {example }
823
826
963
966
\end {note }
964
967
965
968
\pnum
966
- \begin {note } For point of instantiation of a template,
967
- see~\ref {temp.point }.\end {note }%
969
+ \begin {note }
970
+ For point of instantiation of a template, see~\ref {temp.point }.
971
+ \end {note }
968
972
\indextext {scope!declarations and|)}
973
+ \indextext {declaration!point of|)}
969
974
970
975
\rSec 2[basic.scope.block]{Block scope}
971
976
2590
2595
2591
2596
\pnum
2592
2597
A token sequence beginning with
2593
- \opt {\tcode {export}} \tcode {module} or
2594
- \opt {\tcode {export}} \tcode {import}
2598
+ \opt {\tcode {export}} \tcode {module}
2595
2599
and not immediately followed by \tcode {::}
2596
2600
is never interpreted as the \grammarterm {declaration}
2597
2601
of a \grammarterm {top-level-declaration}.
Original file line number Diff line number Diff line change 273
273
\begin {bnf }
274
274
\nontermdef {preprocessing-token}\br
275
275
header-name\br
276
+ import-keyword\br
276
277
identifier\br
277
278
pp-number\br
278
279
character-literal\br
338
339
except that a \grammarterm {header-name}\iref {lex.header } is only formed
339
340
\begin {itemize }
340
341
\item
341
- within a \tcode {\# include} directive\iref {cpp.include },
342
+ after the \tcode {include} or \tcode {import} preprocessing token in an
343
+ \tcode {\# include}\iref {cpp.include } or
344
+ \tcode {import}\iref {cpp.import } directive, or
342
345
343
346
\item
344
- within a \grammarterm {has-include-expression}, or
347
+ within a \grammarterm {has-include-expression}.
345
348
346
- \item
347
- outside of any preprocessing directive,
348
- if applying phase 4 of translation to the sequence
349
- of preprocessing tokens produced thus far
350
- is valid and
351
- results in an \grammarterm {import-seq}\iref {cpp.module }.
352
349
\end {itemize }
353
350
\end {itemize }
354
351
359
356
\end {codeblock }
360
357
\end {example }
361
358
359
+ \pnum
360
+ The \grammarterm {import-keyword} is produced
361
+ by processing an \tcode {import} directive\iref {cpp.import } and
362
+ has no associated grammar productions.
363
+
362
364
\pnum
363
365
\begin {example } The program fragment \tcode {0xe+foo} is parsed as a
364
366
preprocessing number token (one that is not a valid floating or integer
Original file line number Diff line number Diff line change 411
411
412
412
\begin {bnf }
413
413
\nontermdef {module-import-declaration}\br
414
- \opt {\keyword {export}} \keyword { import} module-name \opt {attribute-specifier-seq} \terminal {;}\br
415
- \opt {\keyword {export}} \keyword { import} module-partition \opt {attribute-specifier-seq} \terminal {;}\br
416
- \opt {\keyword {export}} \keyword { import} header-name \opt {attribute-specifier-seq} \terminal {;}
414
+ \opt {\keyword {export}} import-keyword module-name \opt {attribute-specifier-seq} \terminal {;}\br
415
+ \opt {\keyword {export}} import-keyword module-partition \opt {attribute-specifier-seq} \terminal {;}\br
416
+ \opt {\keyword {export}} import-keyword header-name \opt {attribute-specifier-seq} \terminal {;}
417
417
\end {bnf }
418
418
419
419
\pnum
478
478
a \grammarterm {header-name} is also recognized by the
479
479
preprocessor, and results in macros defined at the
480
480
end of phase 4 of translation of the header unit
481
- being made visible as described in \ref {cpp.module }.
481
+ being made visible as described in \ref {cpp.import }.
482
482
\end {note }
483
483
A declaration of a name with internal linkage is
484
484
permitted within a header unit despite all
You can’t perform that action at this time.
0 commit comments