[Bug c/30260] Enumeration types and enumeration constants erroneously given unsigned types

2008-08-24 Thread rda at lemma-one dot com
--- Comment #7 from rda at lemma-one dot com 2008-08-24 14:02 --- The gcc 4.4 semantics as described by Manuel do not conform to the standard in either case. B2 is the integer -1 which is less than 0, so B2 < 0 should be 1 not 0. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30260

[Bug c/30260] New: Enumeration types and enumeration constants erroneously given unsigned types

2006-12-19 Thread rda at lemma-one dot com
t' * * but with code that correctly prints out: * (a < 0) = 1, (A2 < 0) = 1, A{1,2} = +0, -1 (b < 0) = 1, (B2 < 0) = 1, B{1,2} = +0, -1 * * Rob Arthan (rda at lemma-one dot com) 19th December 2006 */ #include enum A {A1 = 0, A2 = A1 - 1}; enum B {B1 = 0u, B2 = B1 - 1}; int m