<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/139058>139058</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
Flags specifics to a language mode are not diagnosed in other language modes
</td>
</tr>
<tr>
<th>Labels</th>
<td>
clang:driver
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
cor3ntin
</td>
</tr>
</table>
<pre>
```
clang -x c -fexceptions -frtti -fchar8_t -fcoroutines -fcxx-modules
```
We do not emit diagnostics for `-fexceptions -frtti -fchar8_t`, which are not valid C options.
(but we seem to do for `-fcoroutines -fcxx-modules`)
https://compiler-explorer.com/z/48hc6Krh3
</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJx8kc2O3CoQRp8Gb0puYfBPs2DRd668yQNkGWEo20TYWFDu6eTpI3dbk8wikZBAgjqHqs_k7KcVUbPmP9b8X5id5pi0jUmu5NdiiO6HZi0_F7_ZYNYJygdYKEd8WNzIxzVDOSYiD-VoZ5Ou3-g4xRR38iset_bxKJfo9oCZ8dufRMZvXxFchDUS4OIJnDfTGjN5m2GMCVjL_-k6OOIN3mdvZzAJn6S7Cd7BG8RX0eVlYuI67ATvCBlxAYqH-MPx1x8fAvUizERbZvLGRM9Eb-Oy-YCpxMcWYsJ0sXFhov_JRF9fZ9t-SbMsnJZOSWUK1FVXt61SkvNi1mp0HbZja6TspLDSDsaOXWOdVKpWXBReCy4a3vBrxauG80tXuUZ0rZW1kp2sBlZzXIwPlxDuyyWmqfA576grqXhzLYIZMORnuEI8o2Py5pK_Y2JCHIEnfVSWwz5lVvPgM-XfLPIUUPfBTBnyhtaPRyQUwcDB2s2EsESHH0M_k0MHfoVIM6bPD3Oxp6A_j3DyNO_DObdDfW7lluJ3tMRE_-wpM9Gfbd21-BUAAP__KNzhGg">