llvm-project
72c29fa9 - [C++20] [Modules] [Driver] Emit unused argument warning if we use '-fmodule-output' with non-module input

Commit
1 year ago
[C++20] [Modules] [Driver] Emit unused argument warning if we use '-fmodule-output' with non-module input We required the file name of an 'importable module unit' should end with .cppm (or .ccm, .cxxm, .c++m). But the driver can accept '-fmodule-output' for files with normal suffixes (e.g., .cpp). This is somewhat inconsistency. In this patch, we only claim the option `-fmodule-output` is used if the type of the input file is modules related. Then now the compiler will emit 'unused argument' warnings if the input file is not modules related.
Author
Committer
Parents
Loading