This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/40752] -Wconversion generates false warnings for operands not larger than target type


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40752

Wes <wessjunk at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |wessjunk at gmail dot com

--- Comment #22 from Wes <wessjunk at gmail dot com> 2012-05-05 15:09:22 UTC ---
I agree with David.  My code has many instances of things like
a+=2
where a is a char and this makes -Wconversion useless to me.

It's too bad, since it would really be helpful as I am in the process of
changing some data types in the code.

If someone really thinks there should be a warning for this behavior, how about
adding a separate
-Wchar-arithmetic
warning which warns on all char arithmetic and see how much people use it.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]