Skip to content
  • Emmanuel Fleury's avatar
    Fixing signedness warning in sindent():gtester.c · 94029409
    Emmanuel Fleury authored
    ../glib.git/glib/gtester.c: In function ‘sindent’:
    ../glib.git/glib/gmacros.h:351:26: error: comparison of integer expressions of different signedness: ‘guint’ {aka ‘unsigned int’} and ‘int’ [-Werror=sign-compare]
     #define MIN(a, b)  (((a) < (b)) ? (a) : (b))
                              ^
    ../glib.git/glib/gtester.c:73:7: note: in expansion of macro ‘MIN’
       n = MIN (n, l);
           ^~~
    ../glib.git/glib/gmacros.h:351:41: error: operand of ?: changes signedness from ‘int’ to ‘guint’ {aka ‘unsigned int’} due to unsignedness of other operand [-Werror=sign-compare]
     #define MIN(a, b)  (((a) < (b)) ? (a) : (b))
                                             ^~~
    ../glib.git/glib/gtester.c:73:7: note: in expansion of macro ‘MIN’
       n = MIN (n, l);
           ^~~
    94029409