Created on 2023-05-04.00:00:00 last changed 18 months ago
Subclause 10.3 [module.import] paragraph 5 specifies:
A module-import-declaration that specifies a header-name H imports a synthesized header unit, which is a translation unit formed by applying phases 1 to 7 of translation (5.2 [lex.phases]) to the source file or header nominated by H, which shall not contain a module-declaration. ... An importable header is a member of an implementation-defined set of headers that includes all importable C++ library headers (16.4.2.3 [headers]). H shall identify an importable header. ...
This text seems to recognize that header units may be synthesized from non-headers (i.e. source files), yet a module-import-declaration of the form import header-name is required to name an (importable) header, not an arbitrary source file turned into header unit.
Possible resolution:
Change in 10.3 [module.import] paragraph 5 as follows:
H shall identify an importable header.If H nominates a header, that header shall be an importable header.
History | |||
---|---|---|---|
Date | User | Action | Args |
2023-05-04 00:00:00 | admin | create |