Changed bool to signed integer instead of unsigned char.
authorErik Lindahl <lindahl@cbr.su.se>
Wed, 25 Aug 2010 20:25:07 +0000 (22:25 +0200)
committerErik Lindahl <lindahl@cbr.su.se>
Wed, 25 Aug 2010 20:25:07 +0000 (22:25 +0200)
Since we treat this type similar to the enumerated ones internally,
with names and indices, we get lots of warnings about signed/unsigned
comparisions if the type is not signed, and also warnings about using
'char' array subscripts. The integer has worked on compilers this far,
so let's not make bigger changes than we have to!
(Yeah, I know I was the one who suggested we make it compatible with C++
1-byte-size booleans earlier today. Mea Culpa.)

include/types/simple.h

index 64dcf699a461d29b0bbc74143d70e6ab19e25d7e..7c1d0f1abbcf0740f8e0227e1bc6fb0d03d82359 100644 (file)
@@ -82,7 +82,7 @@ extern "C" {
    * so we cannot use the name 'bool' in our C code anymore.
    */
 
-typedef unsigned char gmx_bool;
+typedef char gmx_bool;
 
 #ifndef FALSE
 #  define FALSE   0