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/49626] Explicit conversion skipped when followed by conversion to a wider type


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

Jason Merrill <jason at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2011.07.12 13:56:39
                 CC|                            |jason at gcc dot gnu.org
          Component|c++                         |c
     Ever Confirmed|0                           |1

--- Comment #2 from Jason Merrill <jason at gcc dot gnu.org> 2011-07-12 13:56:39 UTC ---
This does seem like a bug, since the documentation says "An explicit cast
silences the warning."  This bug also affects the C front end, so I'm changing
the category to C.

unsigned long f()
{
  short sh;
  return (unsigned int)sh;
}


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