[clang] [C++20][Modules] Implement P1857R3 Modules Dependency Discovery (PR #107168)
Hubert Tong via cfe-commits
cfe-commits at lists.llvm.org
Tue Oct 14 09:10:38 PDT 2025
hubert-reinterpretcast wrote:
> Anyhow, even without throwing CWG2947 into the mix, stuff like this is allowed:
>
> ```c++
> export module x _Pragma("GCC warning \"Hi\"");
> ```
The above is working, but the seemingly simpler case is not:
```cpp
export module x; _Pragma("GCC warning \"hi\"");
```
Gives:
```
<stdin>:1:18: warning: extra tokens at end of 'module' directive [-Wextra-tokens]
1 | export module x; _Pragma("GCC warning \"hi\"");
| ^
| //
<stdin>:1:18: error: a type specifier is required for all declarations
1 warning and 1 error generated.
```
https://github.com/llvm/llvm-project/pull/107168
More information about the cfe-commits
mailing list