Title
Redundant ill-formedness for module macros
Status
tentatively ready
Section
15.5 [cpp.module]
Submitter
Hubert Tong

Created on 2025-09-21.00:00:00 last changed 2 weeks ago

Messages

Date: 2025-09-26.20:51:59

Proposed resolution (approved by CWG 2025-09-26):

  1. Remove 15.5 [cpp.module] paragraph 1:

    A pp-module shall not appear in a context where module or (if it is the first preprocessing token of the pp-module) export is an identifier defined as an object-like macro.
  2. Remove 15.6 [cpp.import] paragraph 1:

    A pp-import shall not appear in a context where import or (if it is the first preprocessing token of the pp-import) export is an identifier defined as an object-like macro.
Date: 2025-09-21.00:00:00

(From submission #766.)

Macro definitions for keywords are prohibited by 15.7.1 [cpp.replace.general] paragraph 9. More limited restrictions in 15.5 [cpp.module] paragraph 1 and 15.6 [cpp.import] paragraph 1 are redundant.

History
Date User Action Args
2025-09-26 20:51:59adminsetstatus: open -> tentatively ready
2025-09-22 19:43:32adminsetmessages: + msg8117
2025-09-21 00:00:00admincreate