Commit 72027ec
committed
[clang][Modules] Respect -fno-cxx-modules as a driver flag (llvm#150349)
The mentioned flag is already both a cc1 & driver flag; however, whether
it is respected was tied to either:
1. Whether it was passed as a cc1 option (`Xclang`)
2. or `-fmodules` accompanying it
This poses a consistency problem where `std=c++20` enables the modules
feature, independent of other module settings.
This patch resolves this issue by checking for the presence
unconditionally & passing it down to cc1 when applicable.1 parent bd45852 commit 72027ec
2 files changed
+10
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3946 | 3946 | | |
3947 | 3947 | | |
3948 | 3948 | | |
3949 | | - | |
3950 | | - | |
| 3949 | + | |
| 3950 | + | |
3951 | 3951 | | |
3952 | 3952 | | |
3953 | 3953 | | |
3954 | 3954 | | |
3955 | 3955 | | |
| 3956 | + | |
| 3957 | + | |
3956 | 3958 | | |
3957 | 3959 | | |
3958 | | - | |
3959 | | - | |
3960 | 3960 | | |
3961 | 3961 | | |
3962 | 3962 | | |
| |||
3965 | 3965 | | |
3966 | 3966 | | |
3967 | 3967 | | |
| 3968 | + | |
| 3969 | + | |
| 3970 | + | |
3968 | 3971 | | |
3969 | 3972 | | |
3970 | 3973 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
6 | 9 | | |
7 | 10 | | |
8 | 11 | | |
| |||
0 commit comments