[Libreoffice-commits] core.git: include/tools

Matteo Casalin matteo.casalin at yahoo.com
Wed Jul 29 01:57:07 PDT 2015


 include/tools/errcode.hxx |  193 +++++++++++++++++++++++-----------------------
 1 file changed, 98 insertions(+), 95 deletions(-)

New commits:
commit 5e6ec5bb145a7223281efd46c659a10fc5a59b58
Author: Matteo Casalin <matteo.casalin at yahoo.com>
Date:   Tue Jul 21 22:57:43 2015 +0200

    errcode.hxx: avoid some Wconversion warnings
    
    Change-Id: I48bb49c7eb472fa493fca71736acc358151e87ac
    Reviewed-on: https://gerrit.libreoffice.org/17308
    Reviewed-by: Eike Rathke <erack at redhat.com>
    Tested-by: Eike Rathke <erack at redhat.com>

diff --git a/include/tools/errcode.hxx b/include/tools/errcode.hxx
index 9914960..0df5e30 100644
--- a/include/tools/errcode.hxx
+++ b/include/tools/errcode.hxx
@@ -22,6 +22,9 @@
 
 #ifndef __RSC
 #include <tools/solar.h>
+#define CAST_TO_UINT32(a) ((sal_uInt32)(a))
+#else
+#define CAST_TO_UINT32(a) (a)
 #endif
 
 /*
@@ -70,11 +73,11 @@ Warning           ||   ||      |
 #define ERRCODE_AREA_SHIFT                13
 #define ERRCODE_DYNAMIC_SHIFT             26
 
-#define ERRCODE_CLASS_MASK                (31UL  <<ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_MASK                CAST_TO_UINT32(31UL  <<ERRCODE_CLASS_SHIFT)
 
-#define ERRCODE_DYNAMIC_START             (1UL   <<ERRCODE_DYNAMIC_SHIFT)
+#define ERRCODE_DYNAMIC_START             CAST_TO_UINT32(1UL   <<ERRCODE_DYNAMIC_SHIFT)
 #define ERRCODE_DYNAMIC_COUNT             31UL
-#define ERRCODE_DYNAMIC_MASK              (31UL  <<ERRCODE_DYNAMIC_SHIFT)
+#define ERRCODE_DYNAMIC_MASK              CAST_TO_UINT32(31UL  <<ERRCODE_DYNAMIC_SHIFT)
 
 #ifdef __RSC
 
@@ -84,50 +87,50 @@ Warning           ||   ||      |
 
 #else
 
-typedef sal_uIntPtr ErrCode;
+typedef sal_uInt32 ErrCode;
 
-inline sal_uIntPtr ERRCODE_TOERRID( sal_uIntPtr x )
+inline sal_uInt32 ERRCODE_TOERRID( ErrCode x )
 {
     return x & ~ERRCODE_DYNAMIC_MASK;
 }
 
-inline sal_uIntPtr ERRCODE_TOERROR( sal_uIntPtr x )
+inline sal_uInt32 ERRCODE_TOERROR( ErrCode x )
 {
     return ((x & ERRCODE_WARNING_MASK) ? 0 : (x & ERRCODE_ERROR_MASK));
 }
 
 #endif
 
-#define ERRCODE_AREA_TOOLS               (0UL   << ERRCODE_AREA_SHIFT)
-#define ERRCODE_AREA_SV                  (1UL   << ERRCODE_AREA_SHIFT)
-#define ERRCODE_AREA_SFX                 (2UL   << ERRCODE_AREA_SHIFT)
-#define ERRCODE_AREA_INET                (3UL   << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_TOOLS               CAST_TO_UINT32(0UL   << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_SV                  CAST_TO_UINT32(1UL   << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_SFX                 CAST_TO_UINT32(2UL   << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_INET                CAST_TO_UINT32(3UL   << ERRCODE_AREA_SHIFT)
 #define ERRCODE_AREA_IO                   ERRCODE_AREA_TOOLS
 
-#define ERRCODE_AREA_LIB1                (8UL   << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_LIB1                CAST_TO_UINT32(8UL   << ERRCODE_AREA_SHIFT)
 #define ERRCODE_AREA_SVX                 ERRCODE_AREA_LIB1
 #define ERRCODE_AREA_SVX_END             (ERRCODE_AREA_SO-1)
-#define ERRCODE_AREA_SO                  (9UL   << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_SO                  CAST_TO_UINT32(9UL   << ERRCODE_AREA_SHIFT)
 #define ERRCODE_AREA_SO_END              (ERRCODE_AREA_SBX-1)
-#define ERRCODE_AREA_SBX                 (10UL   << ERRCODE_AREA_SHIFT)
-#define ERRCODE_AREA_SBX_END             ((11UL  << ERRCODE_AREA_SHIFT) - 1)
-#define ERRCODE_AREA_DB                  (11UL   << ERRCODE_AREA_SHIFT)
-#define ERRCODE_AREA_DB_END              ((12UL  << ERRCODE_AREA_SHIFT) - 1)
-#define ERRCODE_AREA_JAVA                (12UL  << ERRCODE_AREA_SHIFT)
-#define ERRCODE_AREA_JAVA_END            ((13UL  << ERRCODE_AREA_SHIFT) - 1)
-#define ERRCODE_AREA_UUI                 (13UL  << ERRCODE_AREA_SHIFT)
-#define ERRCODE_AREA_UUI_END             ((14UL  << ERRCODE_AREA_SHIFT) - 1)
-#define ERRCODE_AREA_LIB2                (14UL  << ERRCODE_AREA_SHIFT)
-#define ERRCODE_AREA_LIB2_END            ((15UL  << ERRCODE_AREA_SHIFT) - 1)
-#define ERRCODE_AREA_CHAOS               (15UL  << ERRCODE_AREA_SHIFT)
-#define ERRCODE_AREA_CHAOS_END           ((16UL  << ERRCODE_AREA_SHIFT) - 1)
-
-#define ERRCODE_AREA_APP1                (32UL  << ERRCODE_AREA_SHIFT)
-#define ERRCODE_AREA_APP2                (40UL  << ERRCODE_AREA_SHIFT)
-#define ERRCODE_AREA_APP3                (48UL  << ERRCODE_AREA_SHIFT)
-#define ERRCODE_AREA_APP4                (56UL  << ERRCODE_AREA_SHIFT)
-#define ERRCODE_AREA_APP5                (64UL  << ERRCODE_AREA_SHIFT)
-#define ERRCODE_AREA_APP6                (72UL  << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_SBX                 CAST_TO_UINT32(10UL   << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_SBX_END             CAST_TO_UINT32((11UL  << ERRCODE_AREA_SHIFT) - 1)
+#define ERRCODE_AREA_DB                  CAST_TO_UINT32(11UL   << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_DB_END              CAST_TO_UINT32((12UL  << ERRCODE_AREA_SHIFT) - 1)
+#define ERRCODE_AREA_JAVA                CAST_TO_UINT32(12UL  << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_JAVA_END            CAST_TO_UINT32((13UL  << ERRCODE_AREA_SHIFT) - 1)
+#define ERRCODE_AREA_UUI                 CAST_TO_UINT32(13UL  << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_UUI_END             CAST_TO_UINT32((14UL  << ERRCODE_AREA_SHIFT) - 1)
+#define ERRCODE_AREA_LIB2                CAST_TO_UINT32(14UL  << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_LIB2_END            CAST_TO_UINT32((15UL  << ERRCODE_AREA_SHIFT) - 1)
+#define ERRCODE_AREA_CHAOS               CAST_TO_UINT32(15UL  << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_CHAOS_END           CAST_TO_UINT32((16UL  << ERRCODE_AREA_SHIFT) - 1)
+
+#define ERRCODE_AREA_APP1                CAST_TO_UINT32(32UL  << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_APP2                CAST_TO_UINT32(40UL  << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_APP3                CAST_TO_UINT32(48UL  << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_APP4                CAST_TO_UINT32(56UL  << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_APP5                CAST_TO_UINT32(64UL  << ERRCODE_AREA_SHIFT)
+#define ERRCODE_AREA_APP6                CAST_TO_UINT32(72UL  << ERRCODE_AREA_SHIFT)
 
 #define ERRCODE_AREA_SC                  ERRCODE_AREA_APP1
 #define ERRCODE_AREA_SC_END              (ERRCODE_AREA_APP2-1)
@@ -140,109 +143,109 @@ inline sal_uIntPtr ERRCODE_TOERROR( sal_uIntPtr x )
 
 #define ERRCODE_AREA_OFA_END             (ERRCODE_AREA_APP6-1)
 
-#define ERRCODE_CLASS_NONE               (0UL   << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_ABORT              (1UL   << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_GENERAL            (2UL   << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_NOTEXISTS          (3UL   << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_ALREADYEXISTS      (4UL   << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_ACCESS             (5UL   << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_PATH               (6UL   << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_LOCKING            (7UL   << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_PARAMETER          (8UL   << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_SPACE              (9UL   << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_NOTSUPPORTED       (10UL  << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_READ               (11UL  << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_WRITE              (12UL  << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_UNKNOWN            (13UL  << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_VERSION            (14UL  << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_FORMAT             (15UL  << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_CREATE             (16UL  << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_IMPORT             (17UL  << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_EXPORT             (18UL  << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_FILTER             (19UL  << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_SO                 (20UL  << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_SBX                (21UL  << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_RUNTIME            (22UL  << ERRCODE_CLASS_SHIFT)
-#define ERRCODE_CLASS_COMPILER           (23UL  << ERRCODE_CLASS_SHIFT)
-
-#define ERRCODE_NONE                  (0UL)
+#define ERRCODE_CLASS_NONE               CAST_TO_UINT32(0UL   << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_ABORT              CAST_TO_UINT32(1UL   << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_GENERAL            CAST_TO_UINT32(2UL   << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_NOTEXISTS          CAST_TO_UINT32(3UL   << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_ALREADYEXISTS      CAST_TO_UINT32(4UL   << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_ACCESS             CAST_TO_UINT32(5UL   << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_PATH               CAST_TO_UINT32(6UL   << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_LOCKING            CAST_TO_UINT32(7UL   << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_PARAMETER          CAST_TO_UINT32(8UL   << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_SPACE              CAST_TO_UINT32(9UL   << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_NOTSUPPORTED       CAST_TO_UINT32(10UL  << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_READ               CAST_TO_UINT32(11UL  << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_WRITE              CAST_TO_UINT32(12UL  << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_UNKNOWN            CAST_TO_UINT32(13UL  << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_VERSION            CAST_TO_UINT32(14UL  << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_FORMAT             CAST_TO_UINT32(15UL  << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_CREATE             CAST_TO_UINT32(16UL  << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_IMPORT             CAST_TO_UINT32(17UL  << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_EXPORT             CAST_TO_UINT32(18UL  << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_FILTER             CAST_TO_UINT32(19UL  << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_SO                 CAST_TO_UINT32(20UL  << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_SBX                CAST_TO_UINT32(21UL  << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_RUNTIME            CAST_TO_UINT32(22UL  << ERRCODE_CLASS_SHIFT)
+#define ERRCODE_CLASS_COMPILER           CAST_TO_UINT32(23UL  << ERRCODE_CLASS_SHIFT)
+
+#define ERRCODE_NONE                  CAST_TO_UINT32(0UL)
 #define ERRCODE_ABORT                 ERRCODE_IO_ABORT
 
-#define ERRCODE_IO_MISPLACEDCHAR      (1UL |ERRCODE_CLASS_PARAMETER|\
+#define ERRCODE_IO_MISPLACEDCHAR      CAST_TO_UINT32(1UL |ERRCODE_CLASS_PARAMETER|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_NOTEXISTS          (2UL |ERRCODE_CLASS_NOTEXISTS|\
+#define ERRCODE_IO_NOTEXISTS          CAST_TO_UINT32(2UL |ERRCODE_CLASS_NOTEXISTS|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_ALREADYEXISTS      (3UL |ERRCODE_CLASS_ALREADYEXISTS|\
+#define ERRCODE_IO_ALREADYEXISTS      CAST_TO_UINT32(3UL |ERRCODE_CLASS_ALREADYEXISTS|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_NOTADIRECTORY      (4UL |ERRCODE_CLASS_PARAMETER|\
+#define ERRCODE_IO_NOTADIRECTORY      CAST_TO_UINT32(4UL |ERRCODE_CLASS_PARAMETER|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_NOTAFILE           (5UL |ERRCODE_CLASS_PARAMETER|\
+#define ERRCODE_IO_NOTAFILE           CAST_TO_UINT32(5UL |ERRCODE_CLASS_PARAMETER|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_INVALIDDEVICE      (6UL |ERRCODE_CLASS_PATH|\
+#define ERRCODE_IO_INVALIDDEVICE      CAST_TO_UINT32(6UL |ERRCODE_CLASS_PATH|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_ACCESSDENIED       (7UL |ERRCODE_CLASS_ACCESS|\
+#define ERRCODE_IO_ACCESSDENIED       CAST_TO_UINT32(7UL |ERRCODE_CLASS_ACCESS|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_LOCKVIOLATION      (8UL |ERRCODE_CLASS_LOCKING|\
+#define ERRCODE_IO_LOCKVIOLATION      CAST_TO_UINT32(8UL |ERRCODE_CLASS_LOCKING|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_OUTOFSPACE         (9UL |ERRCODE_CLASS_SPACE|\
+#define ERRCODE_IO_OUTOFSPACE         CAST_TO_UINT32(9UL |ERRCODE_CLASS_SPACE|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_ISWILDCARD         (11UL|ERRCODE_CLASS_PARAMETER|\
+#define ERRCODE_IO_ISWILDCARD         CAST_TO_UINT32(11UL|ERRCODE_CLASS_PARAMETER|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_NOTSUPPORTED       (12UL|ERRCODE_CLASS_NOTSUPPORTED|\
+#define ERRCODE_IO_NOTSUPPORTED       CAST_TO_UINT32(12UL|ERRCODE_CLASS_NOTSUPPORTED|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_GENERAL            (13UL|ERRCODE_CLASS_GENERAL|\
+#define ERRCODE_IO_GENERAL            CAST_TO_UINT32(13UL|ERRCODE_CLASS_GENERAL|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_TOOMANYOPENFILES   (14UL|ERRCODE_CLASS_SPACE|\
+#define ERRCODE_IO_TOOMANYOPENFILES   CAST_TO_UINT32(14UL|ERRCODE_CLASS_SPACE|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_CANTREAD           (15UL|ERRCODE_CLASS_READ|\
+#define ERRCODE_IO_CANTREAD           CAST_TO_UINT32(15UL|ERRCODE_CLASS_READ|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_CANTWRITE          (16UL|ERRCODE_CLASS_WRITE|\
+#define ERRCODE_IO_CANTWRITE          CAST_TO_UINT32(16UL|ERRCODE_CLASS_WRITE|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_OUTOFMEMORY        (17UL|ERRCODE_CLASS_SPACE|\
+#define ERRCODE_IO_OUTOFMEMORY        CAST_TO_UINT32(17UL|ERRCODE_CLASS_SPACE|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_CANTSEEK           (18UL|ERRCODE_CLASS_GENERAL|\
+#define ERRCODE_IO_CANTSEEK           CAST_TO_UINT32(18UL|ERRCODE_CLASS_GENERAL|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_CANTTELL           (19UL|ERRCODE_CLASS_GENERAL|\
+#define ERRCODE_IO_CANTTELL           CAST_TO_UINT32(19UL|ERRCODE_CLASS_GENERAL|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_WRONGVERSION       (20UL|ERRCODE_CLASS_VERSION|\
+#define ERRCODE_IO_WRONGVERSION       CAST_TO_UINT32(20UL|ERRCODE_CLASS_VERSION|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_WRONGFORMAT        (21UL|ERRCODE_CLASS_FORMAT|\
+#define ERRCODE_IO_WRONGFORMAT        CAST_TO_UINT32(21UL|ERRCODE_CLASS_FORMAT|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_INVALIDCHAR        (22UL|ERRCODE_CLASS_PARAMETER|\
+#define ERRCODE_IO_INVALIDCHAR        CAST_TO_UINT32(22UL|ERRCODE_CLASS_PARAMETER|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_UNKNOWN            (23UL|ERRCODE_CLASS_UNKNOWN|\
+#define ERRCODE_IO_UNKNOWN            CAST_TO_UINT32(23UL|ERRCODE_CLASS_UNKNOWN|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_INVALIDACCESS      (24UL|ERRCODE_CLASS_ACCESS|\
+#define ERRCODE_IO_INVALIDACCESS      CAST_TO_UINT32(24UL|ERRCODE_CLASS_ACCESS|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_CANTCREATE         (25UL|ERRCODE_CLASS_CREATE|\
+#define ERRCODE_IO_CANTCREATE         CAST_TO_UINT32(25UL|ERRCODE_CLASS_CREATE|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_INVALIDPARAMETER   (26UL|ERRCODE_CLASS_PARAMETER|\
+#define ERRCODE_IO_INVALIDPARAMETER   CAST_TO_UINT32(26UL|ERRCODE_CLASS_PARAMETER|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_ABORT              (27UL|ERRCODE_CLASS_ABORT|\
+#define ERRCODE_IO_ABORT              CAST_TO_UINT32(27UL|ERRCODE_CLASS_ABORT|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_NOTEXISTSPATH      (28UL |ERRCODE_CLASS_NOTEXISTS|\
+#define ERRCODE_IO_NOTEXISTSPATH      CAST_TO_UINT32(28UL |ERRCODE_CLASS_NOTEXISTS|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_PENDING            (29UL |ERRCODE_CLASS_NOTEXISTS|\
+#define ERRCODE_IO_PENDING            CAST_TO_UINT32(29UL |ERRCODE_CLASS_NOTEXISTS|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_RECURSIVE          (30UL |ERRCODE_CLASS_PARAMETER|\
+#define ERRCODE_IO_RECURSIVE          CAST_TO_UINT32(30UL |ERRCODE_CLASS_PARAMETER|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_NAMETOOLONG        (31UL |ERRCODE_CLASS_PARAMETER|\
+#define ERRCODE_IO_NAMETOOLONG        CAST_TO_UINT32(31UL |ERRCODE_CLASS_PARAMETER|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_INVALIDLENGTH      (32UL |ERRCODE_CLASS_PARAMETER|\
+#define ERRCODE_IO_INVALIDLENGTH      CAST_TO_UINT32(32UL |ERRCODE_CLASS_PARAMETER|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_CURRENTDIR         (33UL |ERRCODE_CLASS_PARAMETER|\
+#define ERRCODE_IO_CURRENTDIR         CAST_TO_UINT32(33UL |ERRCODE_CLASS_PARAMETER|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_NOTSAMEDEVICE      (34UL |ERRCODE_CLASS_PARAMETER|\
+#define ERRCODE_IO_NOTSAMEDEVICE      CAST_TO_UINT32(34UL |ERRCODE_CLASS_PARAMETER|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_DEVICENOTREADY     (35UL |ERRCODE_CLASS_READ|\
+#define ERRCODE_IO_DEVICENOTREADY     CAST_TO_UINT32(35UL |ERRCODE_CLASS_READ|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_BADCRC             (36UL |ERRCODE_CLASS_READ|\
+#define ERRCODE_IO_BADCRC             CAST_TO_UINT32(36UL |ERRCODE_CLASS_READ|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_WRITEPROTECTED     (37UL |ERRCODE_CLASS_ACCESS|\
+#define ERRCODE_IO_WRITEPROTECTED     CAST_TO_UINT32(37UL |ERRCODE_CLASS_ACCESS|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_BROKENPACKAGE      (38UL |ERRCODE_CLASS_FORMAT|\
+#define ERRCODE_IO_BROKENPACKAGE      CAST_TO_UINT32(38UL |ERRCODE_CLASS_FORMAT|\
                                          ERRCODE_AREA_IO)
-#define ERRCODE_IO_NOTSTORABLEINBINARYFORMAT      (39UL |ERRCODE_CLASS_FORMAT|\
+#define ERRCODE_IO_NOTSTORABLEINBINARYFORMAT      CAST_TO_UINT32(39UL |ERRCODE_CLASS_FORMAT|\
                                          ERRCODE_AREA_IO)
 
 // FsysErrorCodes


More information about the Libreoffice-commits mailing list