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++/15069] a bit test on a variable of enum type is miscompiled


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-04-22 15:58 -------
Yes I am correct in that you are invoking undefined behavior as direction_t can only have values 
between 0 and 5 because C++ rules are different than C.  In C enum types have the same size of the 
underlining type but C++ is different in that respect.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |INVALID


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


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