[PATCH] D52835: [Diagnostics] Check integer to floating point number implicit conversions

Dávid Bolvanský via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Oct 11 12:52:39 PDT 2018


xbolva00 added inline comments.


================
Comment at: lib/Sema/SemaChecking.cpp:10881-10882
+        S.DiagRuntimeBehavior(
+            E->getExprLoc(), E,
+            S.PDiag(diag::warn_impcast_literal_float_to_integer)
+                << E->getType() << T << PrettySourceValue << PrettyTargetValue
----------------
efriedma wrote:
> It looks like this is reusing an existing diagnostic; what warning flag is this controlled by?  It it possible we need a separate flag for this warning?
This is in LiteralConversion.


https://reviews.llvm.org/D52835





More information about the cfe-commits mailing list