[Bug c++/55783] Warnings instead of compiler errors for narrowing conversions within list-initializations
redi at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Sat Dec 22 00:55:00 GMT 2012
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55783
Jonathan Wakely <redi at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |diagnostic
--- Comment #8 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-12-22 00:55:31 UTC ---
Comment 6 misinterprets the standard in multiple ways :)
Narrowing conversions do require a diagnostic, but a warning *is* a diagnostic,
so G++ is compliant in this regard, this is not a GNU extension.
Whether the diagnostic should default to a warning or an error or a "pedwarn"
(the category of diagnostic enabled by -pedantic and made into errors by
-pedantic-errors) is debatable, but the current behaviour is the result of a
conscious decision and is not a bug (certainly not Severity=major)
More information about the Gcc-bugs
mailing list