================
@@ -72,7 +72,9 @@ def warn_pragma_debug_unexpected_argument : Warning<
 
 def warn_fp_nan_inf_when_disabled : Warning<
   "use of %select{infinity|NaN}0%select{| via a macro}1 is undefined behavior "
-  "due to the currently enabled floating-point options">,
+  "due to the currently enabled floating-point options%select{|; mix of safe "
+  "and unsafe math options are used. Check the order of you command line "
+  "arguments}2">,
----------------
AaronBallman wrote:

```suggestion
  "due to the currently enabled floating-point options">,
```
I think we want to drop the advice to check command line arguments because it 
could also be the result of using pragmas as well. I think we can lean on 
calling it out as undefined behavior to tell the user that something is wrong 
somewhere.

I think we could instead add some documentation to `DiagnosticDocs.td` about 
the command line and pragmas potentially impacting things, and then link those 
docs with the `nan-infinity-disabled` warning group.

https://github.com/llvm/llvm-project/pull/80290
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to