diff options
author | Caolán McNamara <caolanm@redhat.com> | 2012-06-14 14:42:28 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2012-06-15 15:41:12 +0100 |
commit | 57ea40b8b638ebbc8d7b5ade81bed3096c47ee95 (patch) | |
tree | 5bf64a3b4106375f396c5844fd47bb8ccd690dd9 /cppu | |
parent | 8a8ca66139bacd7b768bcfa20121c45f8fcf7019 (diff) |
WaE: clear higher debugging levels warnings
Change-Id: I611dc412b5461f368f23aa8239e48d0e175f5168
Diffstat (limited to 'cppu')
-rw-r--r-- | cppu/source/uno/data.cxx | 23 |
1 files changed, 19 insertions, 4 deletions
diff --git a/cppu/source/uno/data.cxx b/cppu/source/uno/data.cxx index d9209c7635d2..9619dbf61de1 100644 --- a/cppu/source/uno/data.cxx +++ b/cppu/source/uno/data.cxx @@ -357,15 +357,30 @@ CPPU_DLLPUBLIC sal_Bool SAL_CALL uno_type_isAssignableFromData( #define MAX_ALIGNMENT_4 #endif -#define OFFSET_OF( s, m ) reinterpret_cast< int >((char *)&((s *)16)->m -16) +#define OFFSET_OF( s, m ) reinterpret_cast< size_t >((char *)&((s *)16)->m -16) #define BINTEST_VERIFY( c ) \ - if (! (c)) { fprintf( stderr, "### binary compatibility test failed: %s [line %d]!!!\n", #c, __LINE__ ); abort(); } + if (! (c)) \ + { \ + fprintf( stderr, "### binary compatibility test failed: %s [line %d]!!!\n", #c, __LINE__ ); \ + abort(); \ + } + #define BINTEST_VERIFYOFFSET( s, m, n ) \ - if (OFFSET_OF(s, m) != n) { fprintf( stderr, "### OFFSET_OF(" #s ", " #m ") = %" SAL_PRI_SIZET "u instead of expected %d!!!\n", OFFSET_OF(s, m), n ); abort(); } + if (OFFSET_OF(s, m) != static_cast<size_t>(n)) \ + { \ + fprintf(stderr, "### OFFSET_OF(" #s ", " #m ") = %" SAL_PRI_SIZET "u instead of expected %" SAL_PRI_SIZET "u!!!\n", \ + OFFSET_OF(s, m), static_cast<size_t>(n)); \ + abort(); \ + } #define BINTEST_VERIFYSIZE( s, n ) \ - if (sizeof(s) != n) { fprintf( stderr, "### sizeof(" #s ") = %d instead of expected %d!!!\n", (int)sizeof(s), n ); abort(); } + if (sizeof(s) != static_cast<size_t>(n)) \ + { \ + fprintf(stderr, "### sizeof(" #s ") = %" SAL_PRI_SIZET "u instead of expected %" SAL_PRI_SIZET "u!!!\n", \ + sizeof(s), static_cast<size_t>(n)); \ + abort(); \ + } struct C1 { |