This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21 Core Issues List revision 120c. See http://www.open-std.org/jtc1/sc22/wg21/ for the official list.
2026-09-04
(From submission #979.)
Preprocessing directives are deleted at the end of phase 4 (5.2 [lex.phases] bullet 1.4), but nothing is done for pp-global-module-fragment or pp-private-module-fragment (which are preprocessing directives per 15.1 [cpp.pre] paragraph 2) to prevent this deletion.
Proposed resolution (approved by CWG 2026-09-01):
Change in 15.5 [cpp.module] paragraph 2 as follows:
The module and export (if it exists) preprocessing tokens of a pp-module, pp-global-module-fragment, or pp-private-module-fragment are replaced by the module-keyword and export-keyword preprocessing tokens respectively. [Note 1: This makes the line no longer a directive so it is not removed at the end of phase 4. —end note] ...