[cpp.module] (original) (raw)

15 Preprocessing directives [cpp]

15.4 Module directive [cpp.module]

A pp-module shall not appear in a context where moduleor (if it is the first token of the pp-module) exportis an identifier defined as an object-like macro.

Any preprocessing tokens after the module preprocessing token in the module directive are processed just as in normal text.

[Note 1:

Each identifier currently defined as a macro name is replaced by its replacement list of preprocessing tokens.

— _end note_]

The module and export (if it exists) preprocessing tokens are replaced by the module-keyword and_export-keyword_ preprocessing tokens respectively.

[Note 2:

This makes the line no longer a directive so it is not removed at the end of phase 4.

— _end note_]